diff options
author | des <des@FreeBSD.org> | 2002-10-29 10:12:51 +0000 |
---|---|---|
committer | des <des@FreeBSD.org> | 2002-10-29 10:12:51 +0000 |
commit | ce26c10eda4d687d476e9bbac51ccd26564af8da (patch) | |
tree | b77463179918969979f21ba706793b6798404415 /crypto | |
parent | 4d499f34f8d029f7dbe293f4de0cd9081cdfea0f (diff) | |
download | FreeBSD-src-ce26c10eda4d687d476e9bbac51ccd26564af8da.zip FreeBSD-src-ce26c10eda4d687d476e9bbac51ccd26564af8da.tar.gz |
Protect against tag expansion + fix some brainos.
Diffstat (limited to 'crypto')
-rw-r--r-- | crypto/openssh/FREEBSD-tricks | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/crypto/openssh/FREEBSD-tricks b/crypto/openssh/FREEBSD-tricks index 9d09e2e..7234126 100644 --- a/crypto/openssh/FREEBSD-tricks +++ b/crypto/openssh/FREEBSD-tricks @@ -1,20 +1,20 @@ # $FreeBSD$ # Shell code to remove FreeBSD tags before merging -grep -rl '\$FreeBSD:' | +grep -rl '\$Fre.BSD:' . | while read f ; do - sed -i.orig -e '/\$FreeBSD:/d' + sed -i.orig -e '/\$Fre.BSD:/d' $f done # Shell + Perl code to add FreeBSD tags wherever an OpenBSD or Id tag occurs -egrep -rl '\$(Id|OpenBSD):' | +egrep -rl '\$(Id|OpenBSD):' . | xargs perl -n -i.orig -e 'print; s/\$(Id|OpenBSD): [^\$]*\$/\$FreeBSD\$/ && print' # Shell code to reexpand FreeBSD tags -grep -rl '\$FreeBSD\$' | +grep -rl '\$FreeBSD\$' . | while read f ; do - id=$(cvs diff $f | grep '\$FreeBSD$FreeBSD$\).*/\1/') ; + id=$(cvs diff $f | grep '\$Fre.BSD:' | sed 's/.*\(\$Fre.BSD:.*\$\).*/\1/') ; if [ -n "$id" ] ; then - sed -i.orig -e "s@\\\$FreeBSD\\\$@$id@" $f ; + sed -i.orig -e "s@\\\$Fre.BSD\\\$@$id@" $f ; fi ; done |