'Doing git pull changes the permission of untracked files
I've been having a problem where all files that I don't want to be tracked by git keep changing permission from 644 to 444 whenever I do git pull (I'm currently using CentOS 7). I'm using git-lfs with the .gitattributes contains:
[!.]* filter=lfs diff=lfs merge=lfs -text lockable
I've also set the following in the .git/config
[core]
filemode = false
autocrlf = true
I've been using git-lfs to tracked all type of files that being pushed to the remote server but there are files that I wished stayed and can be edited locally. Its a hassle to change the permission everytime I am pulling the changes from remote.
Solution 1:[1]
If those files are "lockable", that means you chan try and unlock them, using git lfs unlock.
That would change their locked state (444) to one which can be modified (unlocked, 644).
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | VonC |
