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

Re: "git diff" does not show a diff for newly added, binary files

From
Kristoffer Haugsbakk <code@khaugsbakk.name>
Date
Apr 4, 2023, 10:45 UTC
Message-ID
<4e5ac983-a45d-4459-b398-4d092ca2f1c8@app.fastmail.com>
In-Reply-To
<2349908.kWcu0K8Tai@earendil>
On Tue, Apr 4, 2023, at 12:39, Thorsten Otto wrote:
> I would expect "git diff" to output the same information. I don't see a reason 
> why it outputs the diff for a new text file, but not for a binary file?

Has it done that before? As in, has git(1) behaved like the way you expect it to behave on this point before? Because `git diff` has never diffed binary files for me unless I instructed it to do it via some `.gitattributes` configuration.

-- 
Kristoffer Haugsbakk
Previous: Thorsten OttoNext: Thorsten Otto
Message 4 of 10 in “"git diff" does not show a diff for newly added, binary files”
  1. Thorsten OttoApr 4, 2023
  2. Kristoffer HaugsbakkApr 4, 2023
  3. Thorsten OttoApr 4, 2023
  4. Kristoffer HaugsbakkApr 4, 2023
  5. Thorsten OttoApr 4, 2023
  6. Kristoffer HaugsbakkApr 4, 2023
  7. Jeff KingApr 4, 2023
  8. Junio C HamanoApr 4, 2023
  9. Junio C HamanoApr 4, 2023
  10. Jeff KingApr 4, 2023

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.