diff options
author | Colin Guthrie <colin@mageia.org> | 2013-08-20 10:37:25 +0100 |
---|---|---|
committer | Colin Guthrie <colin@mageia.org> | 2013-08-20 10:37:25 +0100 |
commit | b2c30d63561a7b69136b6091468340b54425b43e (patch) | |
tree | 0d0662938638ab11ff1c64478adbe79fbe862fe4 | |
parent | da7c6bd49fa166417176dc9643814f796a8ea0e9 (diff) | |
download | svn-git-migration-b2c30d63561a7b69136b6091468340b54425b43e.tar svn-git-migration-b2c30d63561a7b69136b6091468340b54425b43e.tar.gz svn-git-migration-b2c30d63561a7b69136b6091468340b54425b43e.tar.bz2 svn-git-migration-b2c30d63561a7b69136b6091468340b54425b43e.tar.xz svn-git-migration-b2c30d63561a7b69136b6091468340b54425b43e.zip |
Fix some bash errors when git rev-parse returns nothing (like 3199d029)
-rwxr-xr-x | scripts/mageia-import.sh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/mageia-import.sh b/scripts/mageia-import.sh index 26c4301..dc49f4b 100755 --- a/scripts/mageia-import.sh +++ b/scripts/mageia-import.sh @@ -73,7 +73,7 @@ for tag in $tags; do # Find the oldest ancestor for which the tree is the same parentref="$ref" - while [ $(git rev-parse --quiet --verify "$parentref"^:) = "$reftreesha1" ]; do + while [ "$(git rev-parse --quiet --verify "$parentref"^:)" = "$reftreesha1" ]; do parentref="$parentref"^ done parent=$(git rev-parse "$parentref") @@ -117,7 +117,7 @@ for branch in $branches; do # Find the oldest ancestor for which the tree is the same parentref="$ref" - while [ $(git rev-parse --quiet --verify "$parentref"^:) = "$reftreesha1" ]; do + while [ "$(git rev-parse --quiet --verify "$parentref"^:)" = "$reftreesha1" ]; do parentref="$parentref"^ done parent=$(git rev-parse "$parentref") |