From 35d1bedfcf75095668ceef94bcd22e5ffad97e80 Mon Sep 17 00:00:00 2001 From: Albert Cheng Date: Tue, 26 Oct 1999 14:30:08 -0500 Subject: [svn-r1791] Moved the MANIFEST checking to a separate command file (chkmanifest) so that it can be invoked individually. --- bin/chkmanifest | 42 ++++++++++++++++++++++++++++++++++++++++++ bin/release | 49 +++++++------------------------------------------ 2 files changed, 49 insertions(+), 42 deletions(-) create mode 100755 bin/chkmanifest diff --git a/bin/chkmanifest b/bin/chkmanifest new file mode 100755 index 0000000..a166fe7 --- /dev/null +++ b/bin/chkmanifest @@ -0,0 +1,42 @@ +#!/bin/sh + +# Check that all the files in MANIFEST exist and that (if this is a +# CVS checkout) that all the CVS-managed files appear in the +# MANIFEST. + +verbose=yes +MANIFEST=/tmp/H5_MANIFEST.$$ + +# Copy the manifest file to get a list of file names. +grep '^\.' MANIFEST | expand | cut -f1 -d' ' >$MANIFEST + +test "$verbose" && echo " Checking manifest..." 1>&2 +test -f $MANIFEST || exit 1 +for file in `cat $MANIFEST`; do + if [ ! -f $file ]; then + echo "- $file" + fail=yes + fi +done +for cvs in `find . -type d -name CVS -print`; do + path=`echo $cvs |sed 's/\/CVS//'` + for file in `grep '^\/' $cvs/Entries |cut -d/ -f2`; do + if (grep $path/$file $MANIFEST >/dev/null); then + : + else + echo "+ $path/$file" + fail=yes + fi + done +done + +if [ "X$fail" = "Xyes" ]; then + cat 1>&2 <$MANIFEST - -# Check that all the files in MANIFEST exist and that (if this is a -# CVS checkout) that all the CVS-managed files appear in the -# MANIFEST. -test "$verbose" && echo " Checking manifest..." 1>&2 -test -f $MANIFEST || exit 1 -for file in `cat $MANIFEST`; do - if [ ! -f $file ]; then - echo "- $file" - fail=yes - fi -done -for cvs in `find . -type d -name CVS -print`; do - path=`echo $cvs |sed 's/\/CVS//` - for file in `grep '^\/' $cvs/Entries |cut -d/ -f2`; do - if (grep $path/$file $MANIFEST >/dev/null); then - : - else - echo "+ $path/$file" - fail=yes - fi - done -done -# for file in ./Changes `sh -c 'svf ls' 2>/dev/null`; do -# if (grep $file $MANIFEST >/dev/null); then -# : -# elif [ $file = ./Changes ]; then -# : -# else -# echo "+ $file" -# fail=yes -# fi -# done - +# Check the validity of the MANIFEST file. +bin/chkmanifest || fail=yes if [ "X$fail" = "Xyes" ]; then - cat 1>&2 <$MANIFEST # Prepare the source tree for a release. -- cgit v0.12