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

Re: gitignore design

From
Johannes Sixt <j.sixt@viscovery.net>
Date
Jul 29, 2011, 12:58 UTC
Message-ID
<4E32AE7C.70004@viscovery.net>
In-Reply-To
<m339hps2is.fsf@localhost.localdomain>
Am 7/29/2011 14:19, schrieb Jakub Narebski:
Show 9 quoted lines
> For that you can use 'assume-unachanged' mechanism (note: it is local
> to repository).  The gitignore(7) manpage says:
> 
>   NOTES
>      The purpose of gitignore files is to ensure that certain files not tracked
>      by git remain untracked.
> 
>      To ignore uncommitted changes in a file that is already tracked, use
>      `git update-index --assume-unchanged <file>`.

This statement in our documentation is *wrong*!! Please do not suggest it for cases like the OP's!

See the discussion of assume-unchanged in git-update-index: This bit actually means that git may assume that the file was not changed, and it can take the worktree's data when it otherwise would have to unpack the index's data. IOW, using it for the purposes that the OP would need is *dangerous*.

-- Hannes
Previous: Jakub NarebskiNext: Jakub Narebski
Message 11 of 20 in “gitignore design”
  1. llucianfJul 29, 2011
  2. Ferry HubertsJul 29, 2011
  3. llucianfJul 29, 2011
  4. Ferry HubertsJul 29, 2011
  5. llucianfJul 29, 2011
  6. Jakub NarebskiJul 29, 2011
  7. llucianfJul 29, 2011
  8. Jakub NarebskiJul 29, 2011
  9. Ferry HubertsJul 29, 2011
  10. Jakub NarebskiJul 29, 2011
  11. Johannes SixtJul 29, 2011
  12. Jakub NarebskiJul 29, 2011
  13. Johannes SixtJul 29, 2011
  14. Jakub NarebskiJul 29, 2011
  15. Nguyen Thai Ngoc DuyJul 30, 2011
  16. Piotr KrukowieckiJul 30, 2011
  17. Nguyen Thai Ngoc DuyJul 30, 2011
  18. Piotr KrukowieckiJul 30, 2011
  19. Clemens BuchacherJul 30, 2011
  20. Philip OakleyJul 29, 2011

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.