In this guide I’ll show you, how to prevent permission changes within a Git repository to be recognized as a file change.
At least after changing file permissions using the Makefile
in
your version controlled project, the output of git status
will be a mess making
it nearly impossible to identify changes within your project’s source code.
All this happens although no one really wants to commit changed file permissions. The following command prevents Git from marking files as changed if only the file modes differ.
git config --global core.fileMode false
Inverting this command let you return to the default behavior:
git config --global core.fileMode true