diff options
author | ache <ache@FreeBSD.org> | 1994-05-23 22:13:36 +0000 |
---|---|---|
committer | ache <ache@FreeBSD.org> | 1994-05-23 22:13:36 +0000 |
commit | 007929fd3a9fe6a2eef0bf097cce9bf05d0452c7 (patch) | |
tree | 2e1e3bb14e455c9e9c78a6bf5b3a8fb9baa6073d /gnu/usr.bin/man | |
parent | 1f04a9091b06c7086e3721c1f9d914b2fc84b579 (diff) | |
download | FreeBSD-src-007929fd3a9fe6a2eef0bf097cce9bf05d0452c7.zip FreeBSD-src-007929fd3a9fe6a2eef0bf097cce9bf05d0452c7.tar.gz |
Fix catman to produce zipped cats, like man does.
In other (old) case we have both kind of cats at once.
Diffstat (limited to 'gnu/usr.bin/man')
-rw-r--r-- | gnu/usr.bin/man/catman/catman.sh | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/gnu/usr.bin/man/catman/catman.sh b/gnu/usr.bin/man/catman/catman.sh index e5d23e1..456cb57 100644 --- a/gnu/usr.bin/man/catman/catman.sh +++ b/gnu/usr.bin/man/catman/catman.sh @@ -7,17 +7,19 @@ MANDIR=/usr/share/man formatman() { suffix=`echo $1 | sed -e 's/.*\\.//'` - echo " "$1 "->" $* (cd cat$section; rm -f $*) if [ ".$suffix" = "%compext%" ]; then - %zcat% man$section/$1 | nroff -man | %compress% > cat$section/$1 + adds= + %zcat% man$section/$1 | nroff -man | %compress% > cat$section/$1$adds else - nroff -man < man$section/$1 > cat$section/$1 + adds=%compext% + nroff -man < man$section/$1 | %compress% > cat$section/$1$adds fi - catfile=$1; shift + echo " "$* "->" $1$adds + catfile=$1$adds; shift while [ $# -gt 0 ] do - ln cat$section/$catfile cat$section/$1 + ln cat$section/$catfile cat$section/$1$adds shift done } |