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

Re: allowing aliases to override builtins to support default options

From
Johannes Schindelin <johannes.schindelin@gmx.de>
Date
Mar 7, 2009, 03:10 UTC
Message-ID
<alpine.DEB.1.00.0903070407480.10279@pacific.mpi-cbg.de>
In-Reply-To
<76718490903061857y5446098by3633559697508c2e@mail.gmail.com>
Hi,
On Fri, 6 Mar 2009, Jay Soffian wrote:
> For example, what if:
> 
> 1. The aliases applied only to porcelain commands, not to plumbing.

Inconsistency like this is bad for a couple of reasons. Just 3 out of them:

- it makes it hard for users to understand,
- it is prone for subtle breakages,
- the code will be complicated, and therefore ugly.
> 2. The aliases worked only if stdout was a terminal, using the same 
>    method that git uses for detecting when it is okay to start a pager.

This would be even more complicated to understand for the regular Git user who just wants to use the darned thing and not care about its internals.

> 3. git took --alias-builtins and --no-alias-builtins just like it takes 
>    --paginate and --no-pager to override (2).
And this makes it even more complicated.

I'd rather stay with our current notion that aliases cannot override Git programs. This is _very_ easy to explain, and also _very_ easy to defend.

Ciao, Dscho

Previous: Jay Soffian
Message 7 of 7 in “allowing aliases to override builtins to support default options”
  1. Jay SoffianMar 6, 2009
  2. Sverre RabbelierMar 6, 2009
  3. Junio C HamanoMar 6, 2009
  4. Jay SoffianMar 6, 2009
  5. Johannes SchindelinMar 7, 2009
  6. Jay SoffianMar 7, 2009
  7. Johannes SchindelinMar 7, 2009

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.