[-- Attachment #1: Type: text/plain, Size: 336 bytes --] I just figured out how to do this: $ zhelp() { man zshbuiltins | less -p "^ $1" } $ zhelp read read [ -rszpqAclneE ] [ -t [ num ] ] [ -k [ num ] ] [ -d delim ] [ -u n ] [ name[?prompt] ] [ name ... ] .... ... simple and effective, but I'll bet someone has something better. [-- Attachment #2: Type: text/html, Size: 695 bytes --]
[-- Attachment #1: Type: text/plain, Size: 550 bytes --] you should try typing read (or any other command) than pressing alt-h, by default bound to the run-help widget Il giorno mar 4 ott 2022 alle 20:53 Ray Andrews <rayandrews@eastlink.ca> ha scritto: > I just figured out how to do this: > > $ zhelp() { man zshbuiltins | less -p "^ $1" } > > $ zhelp read > > read [ -rszpqAclneE ] [ -t [ num ] ] [ -k [ num ] ] [ -d delim ] > [ -u n ] [ name[?prompt] ] [ name ... ] > .... > > ... simple and effective, but I'll bet someone has something better. > > > -- Pier Paolo Grassi [-- Attachment #2: Type: text/html, Size: 1394 bytes --]
On 2022-10-04 12:20, Pier Paolo Grassi wrote:
> you should try typing
> read (or any other command) than pressing alt-h, by default bound to
> the run-help widget
>
I think something got lost when I switched to the 'official' Debian copy
of zsh. I do remember run-help being useful but it doesn't work now, it
reports as being an alias of 'man'. And somebody has stolen the alt-h
key, I think xfce owns it now, it brings up a graphical box that shows
me an 'about' for the xterm. Mind I can probably steal it back. If I
can get run-help useful again.
On Tue, Oct 4, 2022 at 9:33 PM Ray Andrews <rayandrews@eastlink.ca> wrote:
>
>
> On 2022-10-04 12:20, Pier Paolo Grassi wrote:
> > you should try typing
> > read (or any other command) than pressing alt-h, by default bound to
> > the run-help widget
> >
> I think something got lost when I switched to the 'official' Debian copy
> of zsh. I do remember run-help being useful but it doesn't work now, it
> reports as being an alias of 'man'
Add this to .zshrc:
autoload -Uz run-help
if [[ -v aliases[run-help] ]]; then
unalias run-help
fi
Roman.
You need unalias run-help autoload run-help somewhere.
On 2022-10-04 12:35, Bart Schaefer wrote:
> You need
> unalias run-help
> autoload run-help
> somewhere.
>
Tried that, no action. In my downloaded zsh I have:
.../functions/run-help
In Debian's version:
.../functions/Misc/run-help
... but running it (sourcing it) directly from there it seems to work fine.
Ah! ... what is it ... zsh's internal path, can't remember what it's
called but it finds this sort of thing. Maybe my configuration isn't
set to find it in 'Misc' -- why would Debian decide to put things where
zsh devs don't want them to be anyway? You guys know where you want
things, why not leave it alone?
% which zman
zman () {
PAGER="less -g -s '+/(?i)^ "$1"'" LANG= man zshall
}
I, personally, don't find read-help that useful (which is suggested in
the other branch of this tread).
Try `run-help run-help` which says that there is nothing to be found,
whereas `zman run-help` shows me what I need :)
- René
Am 04.10.22 um 20:52 schrieb Ray Andrews:
> I just figured out how to do this:
>
> $ zhelp() { man zshbuiltins | less -p "^ $1" }
>
> $ zhelp read
>
> read [ -rszpqAclneE ] [ -t [ num ] ] [ -k [ num ] ] [ -d delim ]
> [ -u n ] [ name[?prompt] ] [ name ... ]
> ....
>
> ... simple and effective, but I'll bet someone has something better.
>
>
On 2022-10-04 14:15, René Neumann wrote:
> % which zman
> zman () {
> PAGER="less -g -s '+/(?i)^ "$1"'" LANG= man zshall
> }
>
I'll play with that, thanks.