I've got two source code directories (different programming languages) and I've noticed that when I alter source files in language A the direct parent modification time also updates. However, in language B, altering sources does not seem to update the parent directory modification times whatsoever.

Honestly, this feels quite weird to me and I can't find a pattern or reason for this. Is this something related to MacOS only? I don't recall every seeing this behaviour in Linux systems.

Can the files have some kind of attribute which tells the OS how to update the parent directories?

I'm on High Sierra using a zsh shell.

  • 1
    Check the source code dir A for invisible files created/deleted by the $editor.app!
    – klanomath
    Jan 21, 2018 at 13:53

1 Answer 1


Your observations seem to be off. In this respect macOS works the same as Linux - the modification time for the parent directory change when you add, remove or rename files/subdirectories in that directory.

The modification time is not changed when you alter the contents of files. Neither on macOS nor on Linux.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .