How do i change the modification/creation date of a folder

348 views Asked by At

For my makefile creating folders on Windows, i need to update folders dates. When i have a newer subfolder, the parent Folders rule will allways be executed even if it exists, cause its date is not updated.

However touchonly works with files. touch on a folder gives touch: creating 'testDir': Permission denied. Is there a command to change dates of folders?

Please ask away if you need an example.

1

There are 1 answers

0
kuga On

I found a solution!

Simply create an empty file in this folder, then delete it. Modification time is updated! Thanks to Lyle Brown