list-cvs-files.sh: Make it work in git subdirectory, too

Signed-off-by: Jan Lindemann <jan@janware.com>
This commit is contained in:
Jan Lindemann 2016-04-30 16:22:30 +00:00
commit 51e512859a

View file

@ -43,12 +43,13 @@ list_dirents()
{
if [ -d $1/CVS ]; then
list_dirents_cvs $1
elif [ -d $1/.git ]; then
list_dirents_git $1
else
return
fi
git status >/dev/null 2>&1 || {
echo "failed to list versioned files in $1: no VCS" >&2
exit 1
fi
}
list_dirents_git $1
}
set -- `getopt f "$@"`