Add --quiet option passed to git-fast-import(1)

Signed-off-by: Rocco Rutte <pdmef@gmx.net>
This commit is contained in:
Rocco Rutte
2007-03-07 11:24:59 +00:00
parent 2b319f9de4
commit cdb66d3298

View File

@@ -1,6 +1,6 @@
#!/bin/sh
USAGE='[-m max] repo'
USAGE='[-m max] [--quiet] repo'
LONG_USAGE='Import hg repository <repo> up to either tip or <max>'
ROOT="`dirname $0`"
REPO=""
@@ -9,6 +9,7 @@ PFX="hg2git"
SFX_MARKS="marks"
SFX_HEADS="heads"
SFX_STATE="state"
QUIET=""
. git-sh-setup
cd_to_toplevel
@@ -20,6 +21,9 @@ do
shift
MAX="$1"
;;
--q|--qu|--qui|--quie|--quiet)
QUIET="--quiet"
;;
-*)
usage
;;
@@ -48,7 +52,7 @@ GIT_DIR="$GIT_DIR" python "$ROOT/hg2git.py" \
"$GIT_DIR/$PFX-$SFX_MARKS" \
"$GIT_DIR/$PFX-$SFX_HEADS" \
"$GIT_DIR/$PFX-$SFX_STATE" \
| git-fast-import --export-marks="$GIT_DIR/$PFX-$SFX_MARKS.tmp" \
| git-fast-import $QUIET --export-marks="$GIT_DIR/$PFX-$SFX_MARKS.tmp" \
|| die 'Git fast-import failed'
# move recent marks cache out of the way...