Browse Source

allow --help to run when called outside a repository

Don't try to run Git commands before having an opportunity to run
'usage' and other help commands.

Fixes #
master
Matthieu Moy 8 years ago
parent
commit
191d640135
  1. 3
      git-latexdiff

3
git-latexdiff

@ -198,7 +198,6 @@ bibtex=0
biber=0 biber=0
output= output=
initial_dir=$PWD initial_dir=$PWD
initial_repo=$(git rev-parse --show-toplevel)
tmpdir_prefix="/tmp" tmpdir_prefix="/tmp"
prepare_cmd= prepare_cmd=
flatten=1 flatten=1
@ -377,6 +376,8 @@ while test $# -ne 0; do
shift shift
done done
initial_repo=$(git rev-parse --show-toplevel)
if test -z "$new" ; then if test -z "$new" ; then
new=HEAD new=HEAD
fi fi

Loading…
Cancel
Save