Test a file date with bash
bash, creation, datetime, file
Solution
Here is the best answer I found at the time being, but it's only for the modification time :
expr `date +%s` - `stat -c %Y /home/user/my_file`
Problem
I am trying to test how old ago a file was created (in seconds) with bash in an `if` statement. I need creation date, not modification. Do you have any idea how to do this, without using a command like `find` with `grep`?