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

Re: [PATCH] git-status.txt: mention --no-optional-locks

From
Johannes Schindelin <johannes.schindelin@gmx.de>
Date
Nov 27, 2017, 20:54 UTC
Message-ID
<alpine.DEB.2.21.1.1711272152510.6482@virtualbox>
In-Reply-To
<b63ecdab-2283-9479-0de6-29a604c09670@gmail.com>
Hi Kaartic,
On Mon, 27 Nov 2017, Kaartic Sivaraam wrote:
Show 10 quoted lines
> On Monday 27 November 2017 11:37 AM, Junio C Hamano wrote:
> > Jeff King <peff@peff.net> writes:
> > > +using `git --no-optional-locks status` (see linkgit:git[1] for details).
> 
> It strikes me just now that `--no-side-effects` might have been a better
> name for the option (of course, iff this avoid all kinds of side
> effects. I'm not sure about the side affects other than index refreshing
> of "git status"). And in case we didn't care about the predictability of
> option names even a little, `--do-what-i-say` might have been a catchy
> alternative ;-)

Your reasoning points to an important insight: while writing index.lock files is a side effect of `git status`, and while there may be other side effects in other operations, it is highly doubtful that any caller would just want to switch them off wholesale. Instead, it is much more likely that callers will want to pick the side effect they want to switch off.

Ciao, Dscho

Previous: Kaartic SivaraamNext: Johannes Schindelin
Message 20 of 33 in “git status always modifies index?”
  1. Nathan NeulingerNov 22, 2017
  2. Santiago TorresNov 22, 2017
  3. Nathan NeulingerNov 22, 2017
  4. Santiago TorresNov 22, 2017
  5. Nathan NeulingerNov 22, 2017
  6. Santiago TorresNov 22, 2017
  7. Jonathan NiederNov 22, 2017
  8. Jeff KingNov 22, 2017
  9. Jonathan NiederNov 22, 2017
  10. Jeff KingNov 22, 2017
  11. Johannes SchindelinNov 25, 2017
  12. Jeff KingNov 26, 2017
  13. Johannes SchindelinNov 26, 2017
  14. Jeff KingNov 27, 2017
  15. Junio C HamanoNov 27, 2017
  16. Johannes SchindelinNov 27, 2017
  17. git-status.txt: mention --no-optional-locksJeff King, Nov 27, 2017
  18. Junio C HamanoNov 27, 2017
  19. Kaartic SivaraamNov 27, 2017
  20. Johannes SchindelinNov 27, 2017
  21. Johannes SchindelinNov 27, 2017
  22. Jonathan NiederNov 27, 2017
  23. Junio C HamanoNov 26, 2017
  24. Junio C HamanoNov 26, 2017
  25. Jeff KingNov 27, 2017
  26. Junio C HamanoNov 27, 2017
  27. Jeff KingNov 27, 2017
  28. Jonathan NiederNov 27, 2017
  29. Jeff KingNov 27, 2017
  30. Junio C HamanoDec 3, 2017
  31. Jeff KingNov 26, 2017
  32. Junio C HamanoNov 27, 2017
  33. Jeff KingNov 27, 2017

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.