I have a github repo which is being used by many users, and assuming more people will join as the project grows. As everyone clones the project i want it to be seamless.
It is a python project, and i have a .env
file for passing the env variables. The file has some variables and some credentials.
I want the .env
file to be untracked as some of the credential fields are distinct for every user and if anyone changes it on local it will be pushed via git add .
.
I tried using git rm --cached
but it removes the file from the github repository.
The closest answer i got is using git update-index --assume-unchanged .env
. But this command will work on local only, if anyone else clones the repository the file will still be tracked.
To summarize, I want to keep the file in the repository, but it should not be tracked by Git.
Any Help Is Appreciated.