2021年4月2日星期五

How can I store a file in GIT in such a way that it will not be tracked?

I have an .ini file in my git repository. It is meant to be a default configuration file documenting possible keys for the user to set. I would like that a user cloning the repository get these defaults. However, later on, each of the users (developers) would modify the .ini according to their preferences. The repository also has a .gitignore file where the .ini is listed. The problem is that I don't know how to tell git not to track this file. What would be the right way to achieve this?

https://stackoverflow.com/questions/66926869/how-can-i-store-a-file-in-git-in-such-a-way-that-it-will-not-be-tracked April 03, 2021 at 09:05AM

没有评论:

发表评论