[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
access different Unix's man pages locally from Emacs
From: |
Emanuel Berg |
Subject: |
access different Unix's man pages locally from Emacs |
Date: |
Sat, 23 May 2020 03:28:44 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) |
If you have access to other Unix systems, it is
likely you run into problems because they don't use
GNU programs. To read a man page over ssh isn't sharp
compared to doing it with the No. 1 Emacs instance -
IMO - so I got the whole thing and put it to
/usr/share/man/ with a sensible name (i.e., openbsd
and sunos), then you can access it from the local
shell with 'man -m openbsd ls' or 'man -m sunos ls'
for the OpenBSD 6.6 (ah, actually they didn't update)
and SunOS 5.10 ls man pages, respectively.
Here is the code - _not complicated_ in terms of code
but very useful.
(defun man-openbsd (page)
(interactive "spage: ")
(man (concat "-m openbsd " page) ))
(defalias 'mano #'man-openbsd)
(defun man-sunos (page)
(interactive "spage: ")
(man (concat "-m sunos " page) ))
(defalias 'mans #'man-sunos)
Some technobabble while I did this:
<incal> yeah! got the SunOS man pages working,
'sudo cp man /usr/share/man/sunos' then
'man -m sunos ls' to get the SunOS 5.10
ls(1) man page! OK, so we know Linux and
GNU people are maximalists under the hood
of minimalism
<https://dataswamp.org/~incal/swamp-imgs/incal-desktop.png>,
OpenBSD people are correct and secure ...
which seems to mean (in part) fewer packs
and very few options compared to the GNU
toolchain - but many options seems to
<incal> be the case for SunOS as well! GNU ls man
page lines: 253, BSD ditto: 291,
SunOS: 737 (!)
<incal> Emacs helpers, line 15-23:
<https://dataswamp.org/~incal/emacs-init/man-my.el>
pZ
--
underground experts united
http://user.it.uu.se/~embe8573
https://dataswamp.org/~incal
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- access different Unix's man pages locally from Emacs,
Emanuel Berg <=