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

Re: Add feature to stop tracking files while keeping them in the index

From
VNViet Nguyen <ntviet18@gmail.com>
Date
Nov 22, 2017, 08:16 UTC
Message-ID
<CANb5NdL3=L-z7E=XSzfKF_JunpDUrwfK101jEAwua8C5_cEooQ@mail.gmail.com>
In-Reply-To
<ba0c7ff2-98b1-7331-dfeb-b6adae0d6207@gmail.com>
Hi Igor,

On November 20, 2017 at 7:15:00 PM, Igor Djordjevic (igor.d.djordjevic@gmail.com) wrote:

Show 18 quoted lines
> Hi Viet,
>
> On 20/11/2017 10:52, Viet Nguyen wrote:
> > Currently, a file can be either tracked or untracked. So, I propose we
> > add a feature to stop tracking files while keeping them in the index.
> >
> > Example scenario:
> > - A developer would like to add some configuration files with example
> > values, e.g. DB_PASSWORD=changeme. But in the future he also want to
> > update those files and to notify the others with conflicts.
>
> If I`m understanding you correctly, what you want should already be
> possible through `git update-index --[no-]skip-worktree`[1].
>
> Regards, Buga
>
> [1] https://git-scm.com/docs/git-update-index#git-update-index---no-skip-worktree
>

We are currently using git-update-index in a client hook, but found it a little tedious because sometime we forget to configure the hooks correctly and it just stop working. So I am thinking that it would be a lot better if we can store it somewhere in the shared repository, so the other developers could ignore the fact that some files in our project are special and treat them just like the regular files.

Best regards,
Viet
Previous: Igor Djordjevic
Message 3 of 3 in “Add feature to stop tracking files while keeping them in the index”
  1. Viet NguyenNov 20, 2017
  2. Igor DjordjevicNov 20, 2017
  3. Viet NguyenNov 22, 2017

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.