Sambit Sambit - 2 months ago 31
Git Question

Git shows all files as modified after changing file permission

I changed the file permission to 777 of a non-bare git repository on Ubuntu OS. After that all files in the repository is showing as modified. I don't want to add all files again and commit. I want to commit the files that I have edited. Is there any way to fix this?

Jin Jin
Answer Source

git config core.fileMode false

This tells git to ignore exec-bit changes.