Author: branden Date: 2004-11-03 11:43:37 -0500 (Wed, 03 Nov 2004) New Revision: 2007
Modified: trunk/debian/CHANGESETS trunk/debian/changelog trunk/debian/rules trunk/debian/scripts/validate-posix-sh Log: Tidy up shell and make style, and tweak wording of change descriptions. Modified: trunk/debian/CHANGESETS =================================================================== --- trunk/debian/CHANGESETS 2004-11-03 13:04:09 UTC (rev 2006) +++ trunk/debian/CHANGESETS 2004-11-03 16:43:37 UTC (rev 2007) @@ -221,13 +221,10 @@ Tidy up and make consistent all Debian-specific manpages. 1964, 2002 -Add simple sanity check on generated maintainer scripts at buildtime and -slightly increase verbosity of validate-posix-sh warnings. - 2004, 2005 +Use validate-posix-sh add build time to perform syntax check generated +maintainer scripts. Increase verbosity of validate-posix-sh warnings. Stop +immediately exiting upon encountering the first shell interpeter that fails on +the script; instead, attempt all the interpreters and report all that fail. + 2004, 2005, 2006, 2007 -Add exit codes to validate-posix-sh, so that it will always run the full test -suite before failing. This change is required to effectively run -valide-posix-sh within debian/rules. - 2006 - vim:set ai et sts=4 sw=4 tw=80: Modified: trunk/debian/changelog =================================================================== --- trunk/debian/changelog 2004-11-03 13:04:09 UTC (rev 2006) +++ trunk/debian/changelog 2004-11-03 16:43:37 UTC (rev 2007) @@ -186,12 +186,12 @@ * Fix nl_BE locale alias information. - * Add simple sanity check on generated maintainer scripts at buildtime and - slightly increase verbosity of validate-posix-sh warnings. + * Use validate-posix-sh add build time to perform syntax check generated + maintainer scripts. - * Add exit codes to validate-posix-sh, so that it will always run the full - test suite before failing. This change is required to effectively run - valide-posix-sh within debian/rules. + * Increase verbosity of validate-posix-sh warnings. Stop immediately + exiting upon encountering the first shell interpeter that fails on the + script; instead, attempt all the interpreters and report all that fail. -- Branden Robinson <[EMAIL PROTECTED]> Sun, 31 Oct 2004 02:22:48 -0500 Modified: trunk/debian/rules =================================================================== --- trunk/debian/rules 2004-11-03 13:04:09 UTC (rev 2006) +++ trunk/debian/rules 2004-11-03 16:43:37 UTC (rev 2007) @@ -185,8 +185,9 @@ cp debian/xserver-xfree86.templates \ debian/xserver-xfree86-dbg.templates - # perform simple sanity check on generated maintainer scripts. - sh debian/scripts/validate-posix-sh debian/*.config debian/*.postinst debian/*.postrm debian/*.preinst debian/*.prerm + # Validate syntax of generated shell scripts. + sh debian/scripts/validate-posix-sh debian/*.config debian/*.postinst \ + debian/*.postrm debian/*.preinst debian/*.prerm touch $@ Modified: trunk/debian/scripts/validate-posix-sh =================================================================== --- trunk/debian/scripts/validate-posix-sh 2004-11-03 13:04:09 UTC (rev 2006) +++ trunk/debian/scripts/validate-posix-sh 2004-11-03 16:43:37 UTC (rev 2007) @@ -11,7 +11,7 @@ DASH="dash -n" KSH="ksh -n" POSH="posh -n" -error="" +ERROR="" usage () { cat <<EOF @@ -43,18 +43,19 @@ for SH in "$ASH" "$BASH" "$DASH" "$KSH" "$POSH"; do CMD=${SH%% *} if which "$CMD" >/dev/null 2>&1; then - if ! $SH $1; then + if ! $SH "$1"; then echo "$PROGNAME: \"$1\" failed syntax check with $CMD" error="yes" fi else - warn "cannot verify correctness of \"$1\" with $CMD; shell not available" + warn "cannot verify correctness of \"$1\" with $CMD; shell not" \ + "available" fi done shift done -if [ -n "$error" ]; then +if [ -n "$ERROR" ]; then exit 1 fi