chrillek Posted December 9, 2022 Posted December 9, 2022 There are "Get path access date" and "Get path modification date". But I'm unable to find "Get path creation date". Is it intentionally missing or am I overlooking something?
vitor Posted December 9, 2022 Posted December 9, 2022 It’s intentional. Unix systems don’t keep track of creation time, though ctime is often confused with it. What macOS shows with a Get Info is kept separate and it is indeed possible to retrieve that info, thought it requires the Developer Tools to be installed. However, even then the creation time can be modified, even by accident. Edit a file with vim and by default its creation time will change to the date of saving. Thus it’s not possible to get a reliable creation time. All that said, I’ll make a note to reevaluate this on a future release of Automation Tasks. Use a Run Script with default settings and stat -f '%B' "${1}" as the code and let me know if it’s good for your use case.
chrillek Posted December 9, 2022 Author Posted December 9, 2022 Good to learn something new. I wasn't actually aware of the fact that most Unix file systems do not track creation time. In that case, I'll go with the modification time – pointless to go hunting for a non-existing value. Thanks a lot!
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now