Changeset 742 for locker/sbin
- Timestamp:
- May 3, 2008, 9:25:20 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
locker/sbin/build-update
r720 r742 90 90 91 91 open (SCRIPT, ">", catfile($outdir, "update")) or die "Couldn't write update: $!"; 92 printf SCRIPT <<'EOF', catfile("/ mit/scripts/deploy/", $old), catfile("/mit/scripts/deploy/", $new);92 printf SCRIPT <<'EOF', catfile("/afs/athena.mit.edu/contrib/scripts/deploy/", $old), catfile("/afs/athena.mit.edu/contrib/scripts/deploy/", $new); 93 93 #!/bin/bash 94 94 set -e -o noclobber 95 95 96 die () { echo "$1" >&2; exit 1; }96 die () { echo "$1" >&2; rm .scripts-security-upd-lock; exit 1; } 97 97 98 98 patchdir=$(dirname "$0") … … 100 100 >.scripts-security-upd-lock || die "error: Unable to obtain update lock." 101 101 102 packages=$(tail - n1 .scripts-version)102 packages=$(tail -1 .scripts-version) 103 103 104 104 echo "[$PWD] begin dry run" … … 116 116 117 117 [ "$found" = "yes" ] || die "error: Correct version not found." 118 xargs -n1 test ! -e <"$patchdir/oldfiles.absent" || die "error: Conflicting files exist." 119 md5sum -c "$patchdir/check.md5" || die "error: MD5 check failed." 118 [ -s "$patchdir/oldfiles.absent" ] && (xargs -n1 test ! -e <"$patchdir/oldfiles.absent" || die "error: Conflicting files exist." ) 119 [ -s "$patchdir/check.md5" ] && (md5sum -c "$patchdir/check.md5" || die "error: MD5 check failed.") 120 120 patch -stN --dry-run --no-backup-if-mismatch -p2 <"$patchdir/update.diff" || die "error: Patch dry run failed." 121 121 … … 126 126 xargs rm -f <"$patchdir/files.delete" 127 127 tar -xzf "$patchdir/newfiles.tar.gz" 128 [ -e "$patchdir/extra/postpatch.sh" ] && . "$patchdir/extra/postpatch.sh" 128 129 ( 129 130 cat .scripts-version.old
Note: See TracChangeset
for help on using the changeset viewer.