Re: What do we have that will save a manpage as we see it on-screen
On Friday 01 October 2021 22:52:59 David Wright wrote:
> On Fri 01 Oct 2021 at 20:53:26 (-0400), Greg Wooledge wrote:
> > On Fri, Oct 01, 2021 at 05:44:41PM -0700, Fred wrote:
> > > man command | col -b > command.txt
> >
> > Curious.
> >
> > unicorn:~$ man ls > ls1
> > unicorn:~$ man ls | col -b > ls2
> > unicorn:~$ ls -l ls1 ls2
> > -rw-r--r-- 1 greg greg 8299 Oct 1 20:49 ls1
> > -rw-r--r-- 1 greg greg 7745 Oct 1 20:49 ls2
> >
> > Glancing at the diff -u between the two files, most of the changes
> > appear to be whitespace related.
> >
> > Opening them both in vim, the second one has a bunch of literal tab
> > characters, whereas the first one has no tabs at all -- only spaces.
> >
> > So I guess most (or all?) of the size reduction is groups of spaces
> > being replaced by tabs.
>
> Yes, diff -ubw will confirm that whitespace is the only difference.
> I'm too lazy to check that the /apparently/ significant differences
> shown by diff and diff -u are merely caused by the left-margin offset,
> which makes TABs skip to different columns from those intended.
>
> Like others, I tried to guess what Gene really wanted (I can barely
> believe the answer) and to come up with a suitable method. I also
> tried out others' suggestions. We don't know what the mysterious
> man 9 actually is (unless there's a well-known command named "9"),
> so I used man man and man bash¹.
There is a well known man 9 command, it means to save man the trouble of
searching the whole database, as there might be duplicate names to
confuse the issue, but it this case look in man/man9 for the requested
manpage. Sheesh, doesn't anyone read manpages anymore? :o)
[...]
Cheers, Gene Heskett.
--
"There are four boxes to be used in defense of liberty:
soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author, 1940)
If we desire respect for the law, we must first make the law respectable.
- Louis D. Brandeis
Genes Web page <http://geneslinuxbox.net:6309/gene>
Reply to: