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

Re: Any way to ignore a change to a tracked file when committing/merging?

From
Nicolas Pitre <nico@cam.org>
Date
Jun 13, 2007, 18:19 UTC
Message-ID
<alpine.LFD.0.99.0706131417320.1697@xanadu.home>
In-Reply-To
<6D50717E-7FB2-48EE-9B56-42B658ACAD10@mimvista.com>
On Wed, 13 Jun 2007, David Watson wrote:
Show 13 quoted lines
> It appears that only applies to untracked files. I am specifically interested
> in ignoring changes to files that are already tracked, unless I'm
> misunderstanding what you're suggesting. I just built the most recent git from
> repo.or.cz/git, and did the following:
> 
> * edit the file I want to "ignore"
> git-status shows this file as modified
> 
> * edit .git/config, set core.excludesfile to myexcludes, containing the name
> of the file I want
> * git add -u
> * git-status
> shows the file I edited as ready to be committed.

I suppose that the behavior of git-add could be modified to honnor the exclude pattern even for already tracked files. Such change would make sense to me.

Nicolas
Previous: David WatsonNext: Robin Rosenberg
Message 7 of 10 in “Any way to ignore a change to a tracked file when committing/merging?”
  1. David WatsonJun 13, 2007
  2. Pierre HabouzitJun 13, 2007
  3. Nicolas PitreJun 13, 2007
  4. David WatsonJun 13, 2007
  5. Nicolas PitreJun 13, 2007
  6. David WatsonJun 13, 2007
  7. Nicolas PitreJun 13, 2007
  8. Robin RosenbergJun 13, 2007
  9. Andy ParkinsJun 13, 2007
  10. Junio C HamanoJun 13, 2007

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.