[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Accessibility of man pages

From: Dirk Gouders
Subject: Re: Accessibility of man pages
Date: Sat, 08 Apr 2023 21:48:13 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux)

Hi Alex,

Colin Watson <> writes:

> On Sat, Apr 08, 2023 at 03:02:59PM +0200, Alejandro Colomar wrote:
>> Colin, I've had a feeling for a long time that compressed pages are
>> not very useful.  These days, storage is cheap.  How would you feel
>> about having the man pages installed uncompressed in Debian?  That
>> would allow running text tools directly in /usr/share/man/.
> I'm not personally all that bothered either way, but it's a
> distribution-wide policy decision rather than something I'd decide on.
> I suspect there are still some people who would push back against the
> space cost.
>> I've had to do that several times, and lucky me that I have the source
>> code of the Linux man-pages checked out in my computers, but other
>> users don't and they might have trouble finding for example which
>> pages talk about RLIMIT_NOFILE.  The only way I know of is:
>> $ grep -rl RLIMIT_NOFILE man*
>> man2/dup.2
>> man2/pidfd_getfd.2
>> man2/open.2
>> man2/fcntl.2
>> man2/poll.2
>> man2/pidfd_open.2
>> man2/getrlimit.2
>> man2/select.2
>> man2/seccomp_unotify.2
>> man3/getdtablesize.3
>> man3/mq_open.3
>> man3/errno.3
>> man3/sysconf.3
>> man5/proc.5
>> man7/unix.7
>> man7/fanotify.7
>> man7/capabilities.7

Sometimes it is good to have options and one would be bzgrep(1).
As far as I know it doesn't understand "-r" but:

$ find /usr/share/man -type f -exec bzgrep -l RLIMIT_NOFILE {} \;

Yes, it's very slow but close to `man -K`:

find...             man -K...

real 107.45         real 96.34
user 117.06         user 70.11
sys 14.43           sys 26.86

[a thought later]

Oh, I found something much faster:

$ time -p find /usr/share/man -type f | xargs bzgrep -l RLIMIT_NOFILE

real 24.30
user 32.34
sys 6.84

Hmm, perhaps, someone has an explanation for this?



reply via email to

[Prev in Thread] Current Thread [Next in Thread]