mirror of
https://github.com/frej/fast-export.git
synced 2026-03-13 05:00:12 +01:00
Give a proper error message when the hg repo is not known
hg-fast-export.sh always passes the --repo flag to hg-fast-export.py. If, for some reason, we have a state file where the repo-url is an empty string the checks in hg-fast-export.py will not work and the user will be confused. Therefore we check that the url is specified before calling hg-fast-export.py.
This commit is contained in:
@@ -70,6 +70,11 @@ if [ x"$REPO" = x -a -f "$GIT_DIR/$PFX-$SFX_STATE" ] ; then
|
||||
echo "Using last hg repository \"$REPO\""
|
||||
fi
|
||||
|
||||
if [ -z "$REPO" ]; then
|
||||
echo "no repo given, use -r flag"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# make sure we have a marks cache
|
||||
if [ ! -f "$GIT_DIR/$PFX-$SFX_MARKS" ] ; then
|
||||
touch "$GIT_DIR/$PFX-$SFX_MARKS"
|
||||
|
||||
Reference in New Issue
Block a user