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

Re: Diffs "from" working directory

From
Linus Torvalds <torvalds@osdl.org>
Date
Nov 20, 2005, 18:13 UTC
Message-ID
<Pine.LNX.4.64.0511201010490.13959@g5.osdl.org>
In-Reply-To
<20051120174359.GA24177@fieldses.org>
On Sun, 20 Nov 2005, J. Bruce Fields wrote:
> 
> That's a diff *to* the working directory.  My complaint was that there
> wasn't a convenient way to get a diff *from* the working directory.
Something like
	git diff -R -M -p
should do it, no?

("git diff" has the strange property that if you give it any diff flags at all, it forgets all the default ones. So it defaults to "-M -p", but if you just say "-R", it will drop its own defaults, and use _just_ "-R").

[ Which is almost certainly not what most users want, but it's practical 
  when you want to get the internal git format. Whether that is important 
  enough to confuse users or not, I dunno ]
		Linus
Previous: J. Bruce FieldsNext: J. Bruce Fields
Message 2 of 12 in “Re: Diffs "from" working directory”
  1. J. Bruce FieldsNov 20, 2005
  2. Linus TorvaldsNov 20, 2005
  3. J. Bruce FieldsNov 20, 2005
  4. Chuck LeverNov 21, 2005
  5. Catalin MarinasNov 21, 2005
  6. Junio C HamanoNov 21, 2005
  7. Catalin MarinasNov 21, 2005
  8. Chuck LeverNov 22, 2005
  9. Linus TorvaldsNov 22, 2005
  10. Chuck LeverNov 22, 2005
  11. Linus TorvaldsNov 22, 2005
  12. Catalin MarinasNov 22, 2005

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.