Here is the scenario:
In my working directory, I have a number of files (let\'s call them A,B,C) that I\'ve edited. I then ran git update-index --assume-uncha
You could use
$ git stash
$ git reset --hard
$ git stash pop
You can do:
git update-index --skip-worktree A
You need to add a .gitignore
file entry for those files if you want to ignore them. Add just the .gitignore
file, commit it and you will now ignore any changes to them.
However, I think you need to tell us why you are doing it, what's the contents of the files, the nature of them (are they artifacts?) - then you'll get the proper answer.
Also, update-index
with the assume-unchanged
is meant to be used to increase performance if your tree on your OS's file system takes a long time to gather changes for a particular path. I would not recommend using it in your case unless you are ignoring those files due to lengthy git status
or git diff
or other command execution times.