manpagez: man pages & more
info coreutils
Home | html | info | man

File: coreutils.info,  Node: File characteristic tests,  Next: String tests,  Prev: Access permission tests,  Up: test invocation

16.3.3 File characteristic tests
--------------------------------

These options test other file characteristics.

‘-e FILE’
     True if FILE exists.

‘-s FILE’
     True if FILE exists and has a size greater than zero.

‘FILE1 -nt FILE2’
     True if FILE1 is newer (according to modification date) than FILE2,
     or if FILE1 exists and FILE2 does not.

‘FILE1 -ot FILE2’
     True if FILE1 is older (according to modification date) than FILE2,
     or if FILE2 exists and FILE1 does not.

‘FILE1 -ef FILE2’
     True if FILE1 and FILE2 have the same device and inode numbers,
     i.e., if they are hard links to each other.

‘-N FILE’
     True if FILE exists and has been modified (mtime) since it was last
     read (atime).

© manpagez.com 2000-2024
Individual documents may contain additional copyright information.