From: Bart Schaefer <schaefer@brasslantern.com>
To: Michele Venturi <dardo82@gmail.com>
Cc: Peter Stephenson <p.w.stephenson@ntlworld.com>, zsh-workers@zsh.org
Subject: Re: How to fix run-help-* functions?
Date: Mon, 13 Mar 2023 09:06:24 -0700 [thread overview]
Message-ID: <CAH+w=7Zf8S_eCgvYjTV3sp5h8ApXwy9SduMKViBe+hha0_OZHg@mail.gmail.com> (raw)
In-Reply-To: <CA+Ds4NtzgeBtHGo9fdXFLc0xFzQM8WfFxoKr6R7OEkT5Y=qV7g@mail.gmail.com>
On Mon, Mar 13, 2023 at 4:14 AM Michele Venturi <dardo82@gmail.com> wrote:
>
> On Tue, Mar 7, 2023, 18:41 Bart Schaefer <schaefer@brasslantern.com> wrote:
>>
>> If you don't do the "make install" part, you get an error about a
>> "shift" count being wrong, which probably looks like a bug rather than
>> a usage problem.
>
> I've tried this but it doesn't make any difference,
When you "configure" or by passing an environment variable to "make"
you can specify a custom location for the help files.
Because run-help is a shell function, it doesn't have a "source file"
and an "object file" so the source itself contains a replacement
string @runhelpdir@ which is updated by the installfns.sh script
during "make install". Yes, we could have put a "run-help.in" file
somewhere and processed that at a different build step to create
run-help, but that complicates installing the rest of the functions.
The help directory is populated by the Util/helpfiles script, which is
run by "make install" in the Doc subdirectory (but I do not recommend
attempting to run make in individual subdirectories rather than
letting the top-level Makefile drive it.)
However, all of that turns out to be necessary but secondary, because
the real problem is that you're using run-help wrong.
You're not intended to type out "run-help sudo" and hit enter, you're
intended to type "sudo" and then invoke the run-help ZLE widget
(normally ESC h or Alt+h), which then calls the run-help function with
some preliminary setup having been done.
Question for the audience is whether we want to consider this a bug
and make it possible to use run-help as a standalone function.
next prev parent reply other threads:[~2023-03-13 16:07 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-07 14:30 Michele Venturi
2023-03-07 17:13 ` Philippe Troin
2023-03-13 11:09 ` Michele Venturi
2023-03-07 17:22 ` Bart Schaefer
2023-03-07 17:31 ` Peter Stephenson
2023-03-07 17:40 ` Bart Schaefer
2023-03-07 18:34 ` Michele Venturi
2023-03-08 0:03 ` Bart Schaefer
2023-03-13 11:14 ` Michele Venturi
2023-03-13 16:06 ` Bart Schaefer [this message]
2023-03-13 18:19 ` Mikael Magnusson
2023-03-13 20:31 ` Bart Schaefer
2023-03-13 20:41 ` Bart Schaefer
2023-03-20 14:37 ` Michele Venturi
2023-03-21 1:05 ` Bart Schaefer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAH+w=7Zf8S_eCgvYjTV3sp5h8ApXwy9SduMKViBe+hha0_OZHg@mail.gmail.com' \
--to=schaefer@brasslantern.com \
--cc=dardo82@gmail.com \
--cc=p.w.stephenson@ntlworld.com \
--cc=zsh-workers@zsh.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).