Zsh Mailing List Archive
Messages sorted by:
Re: Better Help Docs Searching?
- X-seq: zsh-users 26930
- From: Daniel Shahaf <d.s@xxxxxxxxxxxxxxxxxx>
- To: Zach Riggle <zachriggle@xxxxxxxxx>
- Cc: Zsh Users <zsh-users@xxxxxxx>
- Subject: Re: Better Help Docs Searching?
- Date: Sat, 14 Aug 2021 15:41:48 +0000
- Archived-at: <https://zsh.org/users/26930>
- In-reply-to: <CAMP9c5m=oOwSvEaqVF62GF0=BjjMnS8fBEmbcWz9ydxqx=tvZQ@mail.gmail.com>
- List-id: <zsh-users.zsh.org>
- References: <CAMP9c5m=oOwSvEaqVF62GF0=BjjMnS8fBEmbcWz9ydxqx=tvZQ@mail.gmail.com>
Zach Riggle wrote on Sun, Aug 01, 2021 at 05:44:52 -0500:
> A good example is the builtin 'read'. Even knowing it's a builtin,
> and searching the docs  / man pages for builtins, it's still not
> very straightforward to find the docs on 'read'. (There are 91
> matches for "read" on the online docs and 82 in zshbuiltins).
> I checked out the Zsh source, and can trivially find e.g.
> $ git grep 'findex(read)'
> Which is neat, but not quite useful since reading the raw YODL text is
We have a Vim syntax highlighting for yodl files which may help
It should even be possible to create tags for both texinode() and
cindex()/findex()/kindex()/pindex()/tindex()/vindex() instances, using
ctags(1) with a few regexes on the command-line, and then use the usual
tag-jumping commands (:h -t, :h Q_ta).
> YODL itself seems to be end-of-life / deprecated, so I
> don't expect this situation to change, and it would be an immense
> undertaking to rewrite Zsh docs in a different way.
> All of that said, is there any way to easily find keywords / flags in
> either the online docs OR the man pages -- rather than having way too
> many matches for other things that mention the same word (e.g. "read"
> as mentioned above).
You could grep the yodl sources for «(read» _including_ the parentheses.
That would find references to the builtin without finding uses of the
ordinary English word "read". If your $EDITOR doesn't have yodl syntax
highlighting configured, you could then open the same part of the manual
> : https://zsh.sourceforge.io/Doc/Release/Shell-Builtin-Commands.html
> Thanks for your time,
> Zach Riggle
Messages sorted by: