Date: 28 Jan 2002 22:14:00 -0800 From: swear@blarg.net (Gary W. Swearingen) To: Brian Astill <bastill@sa.apana.org.au> Cc: freebsd-questions@FreeBSD.ORG, Roman Neuhauser <neuhauser@mobil.cz>, freebsd-doc@FreeBSD.ORG Subject: Re: A question from a convert from Windows to FreeBSD Message-ID: <o9r8o9lm53.8o9@localhost.localdomain> In-Reply-To: <20020127155418.G32706@roman.mobil.cz> References: <200201260704.g0Q74u864537@fedde.littleton.co.us> <02012713091300.01261@BAPhD.gihon.org.au> <20020127155418.G32706@roman.mobil.cz>
next in thread | previous in thread | raw e-mail | index | archive | help
Roman Neuhauser <neuhauser@mobil.cz> writes: > > From: Brian Astill <bastill@sa.apana.org.au> > > To: freebsd-questions@FreeBSD.ORG > > Subject: Re: A question from a convert from Windows to FreeBSD > > Date: Sun, 27 Jan 2002 13:09:13 +1030 > > > > On Saturday 26 January 2002 17:34, Chris Fedde wrote: > > > You might want to submit a patch to the FreeBSD Documentation project. > > > > Want? - Yes. Be capable of? - No. > > Sure you are capable of submitting patches to man pages. Here's a > short howto: > > 1. step: find the source file: I suggest: $ man -wa passwd /usr/share/man/cat1/passwd.1.gz (source: /usr/share/man/man1/passwd.1.gz) /usr/share/man/man5/passwd.5.gz And you might find this crummy script useful, at least the two echo lines near the bottom. (It'll probably work with first line changed to "sh" too). #!/bin/ksh ## This is ~/bin/prepare-man-for-pr ## Usage: prepare-man-for-pr [section number] command [section number] ## Comments use the example of shutdown command. ## WARNING: script makes bad assumption that all pages are compressed to .gz cd /tmp man -wa $@ echo "NOTICE: Check to see if it's a port (so no PR)." whereis $@ MANPAGE=$(man -w $@) ## Makes "/usr/share/man/man8/shutdown.8.gz". MANPAGE=${MANPAGE##* } MANPAGE=${MANPAGE%)} XXX=${MANPAGE##*/} ## Makes "shutdown.8.gz". NEW=${XXX%.*} ## Makes "shutdown.8". BEG=${NEW%.*} ## Makes "shutdown". END=${NEW##*.} ## Makes "8". OLD=$BEG..orig.$END rm -i /tmp/$XXX /tmp/$NEW /tmp/$OLD ## 2> /dev/null ## Remove "shutdown.8.gz", "shutdown.8" and "orig-shutdown.8" with query. zcat $MANPAGE > $OLD ## So we have somthing like "/tmp/shutdown.8". cp -p $OLD $NEW ## So we have something like "/tmp/shutdown.8" and "/tmp/orig-shutdown.8". echo "groff -mandoc -Tlatin1 /tmp/$NEW | less" echo "diff -u /tmp/$OLD /tmp/$NEW >|/tmp/diffpr" ## So it can be opened with mouse and for diffing after editing. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-doc" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?o9r8o9lm53.8o9>