mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-12-03 08:22:44 +00:00
Make this not fall over screaming if a file isn't found (the user might
not have wanted it).
This commit is contained in:
parent
8bfd187bc2
commit
24ae520b47
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=5956
@ -1,14 +1,13 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
#
|
#
|
||||||
# mkchecksums.sh - generate interactive checksum-checking script.
|
# mkchecksums.sh - generate interactive checksum-checking script.
|
||||||
# Jordan Hubbard
|
# Author: Jordan Hubbard
|
||||||
#
|
#
|
||||||
# This script generates a cksum.sh script from a set of tarballs
|
# This script generates a cksum.sh script from a set of tarballs
|
||||||
# and should not be run by anyone but the release coordinator (there
|
# and should not be run by anyone but the release coordinator (there
|
||||||
# wouldn't be much point).
|
# wouldn't be much point).
|
||||||
#
|
#
|
||||||
# Jordan
|
# $Id: mkchecksums.sh,v 1.1 1995/01/14 07:41:50 jkh Exp $
|
||||||
# $Id: mkchecksums.sh,v 1.2 1994/11/24 22:30:03 phk Exp $
|
|
||||||
#
|
#
|
||||||
|
|
||||||
# Remove any previous attempts.
|
# Remove any previous attempts.
|
||||||
@ -21,5 +20,5 @@ rm -rf CKSUMS do_cksum.sh
|
|||||||
cksum * > CKSUMS
|
cksum * > CKSUMS
|
||||||
|
|
||||||
# Now generate a script for actually verifying the checksums.
|
# Now generate a script for actually verifying the checksums.
|
||||||
awk 'BEGIN {print "rval=0"} { printf("if [ \"\`cksum %s%s%s\`\" != \"%s %s %s\" ]; then dialog --title Error --infobox \"Checksum error detected on %s!\" -1 -1; rval=1; fi\n", "\047", $3, "\047", $1, $2, $3, $3);} END {print "exit $rval"}' < CKSUMS > do_cksum.sh
|
awk 'BEGIN {print "rval=0"} { printf("if [ -f %s ]; then if [ \"\`cksum %s%s%s\`\" != \"%s %s %s\" ]; then dialog --title \"Checksum Error\" --msgbox \"Checksum error detected on %s!\" -1 -1; rval=1; fi; fi\n", $3, "\047", $3, "\047", $1, $2, $3, $3);} END {print "exit $rval"}' < CKSUMS > do_cksum.sh
|
||||||
chmod +x do_cksum.sh
|
chmod +x do_cksum.sh
|
||||||
|
Loading…
Reference in New Issue
Block a user