I changed the file mode by command chmod +111 file.txt then I checked GIT status and it showed:

On branch master Changes not staged for commit: (use "git add ..." to update what will be committed) (use "git checkout -- ..." to discard changes in working directory)

    modified:   file.txt

no changes added to commit (use "git add" and/or "git commit -a")

Then I committed the changes but after then it stopped taking file permission changes into account as even on changing permission level to +777 it shows

On branch master nothing to commit, working tree clean

Why file permission is not being taken into account anymore?


Git tracks exactly one bit of permission: executable or not executable.

You don't say what you mean precisely by "it stopped taking file permission changes into account", but my best guess is that you didn't change the executable permission, and so from Git's point of view, there was no change to take into account.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.