[svn-r26267] Added comments to the bin/chkmanifest script.

Fixed an issue with missing 'svn ls' code.
This commit is contained in:
Dana Robinson 2015-02-21 17:05:09 -05:00
parent cec02b0b3e
commit 2d760d9de6

View File

@ -81,8 +81,13 @@ done
# check those.
svn_stat="$(svn stat -q)"
for file in $svn_stat; do
# Newly added files are not listed by svn ls, which
# we check below..
# The line listing them starts with 'A'.
letter="$(echo $file | head -c 1)"
if [ "$letter" = "A" ]; then
# Convert 'A ' to './' so it matches
# the manifest file name.
path=`echo $file | sed 's/^A\s*/\.\//g'`
# Ignore directories
if [ ! -d $path ]; then
@ -96,15 +101,22 @@ for file in $svn_stat; do
fi
done
# Next check svn info, which gets a list of all files that are
# Next check svn ls, which gets a list of all files that are
# checked in.
svn_ls="$(svn ls -R)"
for file in $svn_ls; do
path="./${file}"
# Ignore directories
if [ ! -d $path ]; then
if (grep ^$path$ $MANIFEST >/dev/null); then
:
else
echo "+ $path"
fail=yes
fi
fi
done
# Finish up
if [ "X$fail" = "Xyes" ]; then
cat 1>&2 <<EOF