mirror of
https://github.com/frej/fast-export.git
synced 2026-02-27 23:00:42 +01:00
Revert "Handle --force option correctly in any position"
This reverts commit 0c5617bf8d.
The changes turned out to require bash. Traditionally we have tried to
stay compatible with plain old sh, so this is a revert.
Closes #195.
This commit is contained in:
@@ -110,7 +110,7 @@ if [ "true" = "$IGNORECASE" ]; then
|
||||
IGNORECASEWARN="true"
|
||||
fi;
|
||||
|
||||
HG2GIT_ARGS=()
|
||||
|
||||
while case "$#" in 0) break ;; esac
|
||||
do
|
||||
case "$1" in
|
||||
@@ -125,10 +125,14 @@ do
|
||||
# pass --force to git-fast-import and hg-fast-export.py
|
||||
GFI_OPTS="$GFI_OPTS --force"
|
||||
IGNORECASEWARN="";
|
||||
break
|
||||
;;
|
||||
# pass all other args down to hg2git.py
|
||||
*)
|
||||
HG2GIT_ARGS+=("$1")
|
||||
-*)
|
||||
# pass any other options down to hg2git.py
|
||||
break
|
||||
;;
|
||||
*)
|
||||
break
|
||||
;;
|
||||
esac
|
||||
shift
|
||||
@@ -183,7 +187,7 @@ $(
|
||||
--mapping "$GIT_DIR/$PFX-$SFX_MAPPING" \
|
||||
--heads "$GIT_DIR/$PFX-$SFX_HEADS" \
|
||||
--status "$GIT_DIR/$PFX-$SFX_STATE" \
|
||||
"${HG2GIT_ARGS[@]}" 3>&- || _e1=$?
|
||||
"$@" 3>&- || _e1=$?
|
||||
echo $_e1 >&3
|
||||
} | \
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user