Re: [PATCH 1/2] help: make sure local html page exists before calling external processes
- From
Eric Sunshine <sunshine@sunshineco.com>
- Date
- Sep 13, 2021, 15:59 UTC
- Message-ID
- <CAPig+cS=fhE1Dm1ESps8SME9XO2+RPJ7LGtquuZQ5XPFB1uk3Q@mail.gmail.com>
- In-Reply-To
- <8674d67a439a23425133fa005e519ebb6ac19c42.1631531219.git.gitgitgadget@gmail.com>
On Mon, Sep 13, 2021 at 7:07 AM Matthias Aßhauer via GitGitGadget <gitgitgadget@gmail.com> wrote:
> We already check that git.html exists, regardless of the page the user wants > to open. Additionally checking wether the requested page exists gives us a
s/wether/whether/
> smoother user experience when it doesn't.
> When calling a git command and there is an error, most users reasonably expect > git to produce an error message on the standard error stream, but in this case > we pass the filepath to git web--browse wich passes it on to a browser (or a
s/wich/which/
> helper programm like xdg-open or start that should in turn open a browser)
s/programm/program/
> without any error and many GUI based browsers or helpers won't output such a > message onto the standard error stream. > > Especialy the helper programs tend to show the corresponding error message in
s/Especialy/Especially/
Show 5 quoted lines
> a message box and wait for user input before exiting. This leaves users in > interactive console sessions without an error message in their console, > without a console prompt and without the help page they expected. > > The performance cost of the additional stat should be negliggible compared to
s/negliggible/negligible/
> the two or more pocesses that we spawn after the checks.
s/pocesses/processes/
> Signed-off-by: Matthias Aßhauer <mha1993@live.de>