|
@ -38,9 +38,11 @@ git_latexdiff_version=1.0 |
|
|
usage () { |
|
|
usage () { |
|
|
cat << EOF |
|
|
cat << EOF |
|
|
Usage: $(basename $0) [options] OLD [NEW] |
|
|
Usage: $(basename $0) [options] OLD [NEW] |
|
|
|
|
|
$(basename $0) [options] OLD -- |
|
|
Call latexdiff on two Git revisions of a file. |
|
|
Call latexdiff on two Git revisions of a file. |
|
|
|
|
|
|
|
|
OLD and NEW are Git revision identifiers. NEW defaults to HEAD. |
|
|
OLD and NEW are Git revision identifiers. NEW defaults to HEAD. |
|
|
|
|
|
If "--" is used for NEW, then diff against the working directory. |
|
|
|
|
|
|
|
|
Options: |
|
|
Options: |
|
|
--help this help message |
|
|
--help this help message |
|
@ -261,7 +263,8 @@ verbose_progress |
|
|
cd ../new || die "Cannot cd to new/" |
|
|
cd ../new || die "Cannot cd to new/" |
|
|
ln -s -t . "$initial_dir"/* |
|
|
ln -s -t . "$initial_dir"/* |
|
|
if test "$new" != "--"; then |
|
|
if test "$new" != "--"; then |
|
|
# if new == "--" then diff working dir |
|
|
|
|
|
|
|
|
# if new == "--" then diff working dir (already there thanks to ln |
|
|
|
|
|
# -s above). |
|
|
git --git-dir="$git_dir" --work-tree=. checkout "$new" -- . || die "checkout failed for new/" |
|
|
git --git-dir="$git_dir" --work-tree=. checkout "$new" -- . || die "checkout failed for new/" |
|
|
fi |
|
|
fi |
|
|
verbose_progress |
|
|
verbose_progress |
|
|