Tag: stat

  • Getting the Last Modification Timestamp of a File with Stat

    If we want to get just the date modified, for a file, in a format of our choosing. This can be done with a utility called stat. The syntax is as follows: stat -f -t “” In this example, we are printing just the date created in the format YYYYMMDD_HHMMSS. stat -f “%Sm” -t “%Y%m%d_%H%M%S”…