baslinux AT lists.ibiblio.org
Subject: Baslinux mailing list
List archive
- From: Lee Forrest <lforrestster AT gmail.com>
- To: baslinux AT lists.ibiblio.org
- Subject: [BL] Fixed My Man Script
- Date: Sat, 30 Dec 2006 19:35:52 +0000
It was overwriting the symlinks to the real manpage with
the real manpage.
Here's the new version:
#!/bin/sh
#for plain text man pages in /usr/man
# put your favorite editor here
ed=/usr/bin/nvi
# first arg to man on the commandline
file=$1
# see if ${1}.gz is a symlink.
if test -h ${file}.gz
#if it is, extract the name of the manpage, minus ".gz"
# and assign it to $file
then file=`ls -l ${file}.gz | sed -n 's/^\(.* \)\(.*\)\(.gz$\)/\2/p'`
fi
gunzip /usr/man/${file}.gz &&
$ed /usr/man/${file} &&
gzip /usr/man/${file}
----------------
Lee
--
BasicLinux: Small is Beautiful
http://www.basiclinux.com.ru
-
[BL] Fixed My Man Script,
Lee Forrest, 12/30/2006
-
Re: [BL] Fixed My Man Script (take two),
Lee Forrest, 12/30/2006
-
Re: [BL] Fixed My Man Script (take two),
Karolis Lyvens, 12/31/2006
- Re: [BL] Fixed My Man Script (take two), Lee Forrest, 12/31/2006
-
Re: [BL] Fixed My Man Script (take two),
Karolis Lyvens, 12/31/2006
-
Re: [BL] Fixed My Man Script (take two),
Lee Forrest, 12/30/2006
Archive powered by MHonArc 2.6.24.