git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] bash-completion: Print a useful error when called in a non-bash shell

From
ASAndrew Sayers <andrew-git@pileofstuff.org>
Date
Jul 29, 2010, 21:29 UTC
Message-ID
<4C51F2C0.8090101@pileofstuff.org>
In-Reply-To
<7v4ofiuuf7.fsf@alter.siamese.dyndns.org>
On 29/07/10 17:25, Junio C Hamano wrote:
Show 8 quoted lines
> 
> I do agree that there need to be a way to find that information for the
> end users, especially for those who just use binary-packaged git given by
> their distros, but this codepath is _not_ the place to do it.
> 
> How about replacing these with something simple like:
> 
>     echo >&2 "You are not running full 'bash'; exiting." ; exit 127

I take your point that this is not the place to advertise the mailing list, although I prefer to include instructions in error messages. Would you be amenable in principle to creating something like `man git-bug`? A quick search doesn't turn up any documents specifically about bug fixing/reporting, and a man page was the first place I thought to look. I'll happily withdraw this patch until I can have a crack at such a page.

Show 9 quoted lines
>> +	BASH_VERSION: {$BASH_VERSION}
>> +	BASHOPTS: {$BASHOPTS}
>> +	SHELLOPTS: {$SHELLOPTS}
>> +	POSIXLY_CORRECT: {$POSIXLY_CORRECT}
>> +EOF
>> +	echo -n "	command line: {"
>> +	tr '\0' ' ' < /proc/$$/cmdline
> 
> This looks like a Linux-ism to me.
Caught red-flippered :)  I'll use `ps` next time.
	- Andrew
Previous: solsTiCe d'HiverNext: Ævar Arnfjörð Bjarmason
Message 4 of 8 in “bash-completion: Print a useful error when called in a non-bash shell”
  1. bash-completion: Print a useful error when called in a non-bash shellAndrew Sayers, Jul 28, 2010
  2. Junio C HamanoJul 29, 2010
  3. solsTiCe d'HiverJul 29, 2010
  4. Andrew SayersJul 29, 2010
  5. Ævar Arnfjörð BjarmasonJul 29, 2010
  6. Junio C HamanoJul 29, 2010
  7. Stephen BoydJul 30, 2010
  8. Johannes SixtAug 6, 2010

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.