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

Interaction between clean/smudge and git status

From
Sergio Callegari <sergio.callegari@gmail.com>
Date
Apr 13, 2008, 23:25 UTC
Message-ID
<loom.20080413T231611-113@post.gmane.org>
Hi,

I have tried for the first time the .gitattributes filter option, setting a clean and a smudge filter for a certain type of files.

What makes me wonder is that using filters, after a clean checkout git status says that everything is changed.

My filter is a very short script that operates on zip files. The clean command re-zips them so that the content is merely stored. The smudge one re-zips them so that the content is deflated again.

This kind of filter helps very much the git repacking when zip files or openoffice files are around.

But unfortunately, with it git shows everything as changed, which is not that nice.

Is this the expected behaviour of the smudge filter? Unfortunately I have been able to find very little documentation on it (only a bit in the gitattributes man page), so maybe I am missing something.

Next: Johannes Sixt
Message 1 of 6 in “Interaction between clean/smudge and git status”
  1. Sergio CallegariApr 13, 2008
  2. Johannes SixtApr 14, 2008
  3. Junio C HamanoApr 14, 2008
  4. Johannes SixtApr 14, 2008
  5. Sergio CallegariApr 14, 2008
  6. Sergio CallegariApr 14, 2008

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.