Languages
[Edit]
EN

Bash - how to check file dates?

10 points
Created by:
Kate_C
19790

1. It can be checked with stat command:

$ stat path/to/file

Example:

$ stat path/to/file
  File: path/to/file
  Size: 6         	Blocks: 8          IO Block: 4096   regular file
Device: 801h/2049d	Inode: 656476      Links: 1
Access: (0644/-rw-r--r--)  Uid: ( 1000/   my_user)   Gid: ( 1000/   my_user)
Access: 2019-08-02 22:29:18.853867483 +0100
Modify: 2019-08-02 22:29:18.853867483 +0100
Change: 2019-08-02 22:29:18.853867483 +0100
 Birth: -

2. Or with ls command:
    - atime - time of last access:

$ ls –lu 

    - mtime - time of last modification

$ ls –l

    - ctime - time of last status change

$ ls –lc
Native Advertising
50 000 ad impressions - 449$
🚀
Get your tech brand or product in front of software developers.
For more information contact us:
Red dot
Dirask - friendly IT community for everyone.

❤️💻 🙂

Join