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

Re: git rm --cached should be git rm --cache or git rm --stage

From
ZHZenaan Harkness <zen@freedbms.net>
Date
Aug 20, 2016, 22:25 UTC
Message-ID
<20160820222519.GC5044@x220-a02>
In-Reply-To
<91F685E894D94BB89892C695B8C1796E@PhilipOakley>
On Sat, Aug 20, 2016 at 08:14:25PM +0100, Philip Oakley wrote:
> From: "Zenaan Harkness" <zen@freedbms.net>
> >
> > Please CC me :)
Show 16 quoted lines
> >  or perhaps something like:
> >  "does not unstage a file, it actually stages the removal of the
> >  file(s) from the repo (assuming it was already committed before) but
> >  leaves the file in your working tree (leaving you with an untracked
> >  file)"
> >
> 
> The easiest way is to simply swap around the two sentences so that the
> positive action is listed first - this better matches people's typical
> cognition. Human Error (by Reason)[1] tells us to Never state warnings and
> caveats after the instruction, and preferably be positive.
> 
> "--cached:
> Working tree files, whether modified or not, will be retained unchanged.
> The option will remove paths from the index (only) to unstage them from
> future commits."
That's much better. +1. Thanks.
Show 11 quoted lines
> >
> >The git "stage" is a primary concept, and a primary noun (one reason
> >many of us have come to appreciate git), and git's cmd line options and
> >help docs ought reflect this.
> >
> >Thanks,
> >Zenaan
> >--
> 
> Philip
> [1] https://www.amazon.com/Human-Error-James-Reason/dp/0521314194
Previous: Philip OakleyNext: Philip Oakley
Message 5 of 6 in “git rm --cached should be git rm --cache or git rm --stage”
  1. Zenaan HarknessAug 20, 2016
  2. Zenaan HarknessAug 20, 2016
  3. Junio C HamanoAug 20, 2016
  4. Philip OakleyAug 20, 2016
  5. Zenaan HarknessAug 20, 2016
  6. Philip OakleyAug 20, 2016

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.