| Example |
True if file named in $a |
| -r $a |
is readable by effective uid/gid |
| -w $a |
is writable effective uid/gid |
| -x $a |
is executable effective uid/gid |
| -o $a |
is owned effective uid/gid |
|
|
| -R $a |
is readable by real uid/gid |
| -W $a |
is writable real uid/gid |
| -X $a |
is executable real uid/gid |
| -O $a |
is owned real uid/gid |
|
|
| -e $a |
exists |
| -z $a |
has zero size |
| -s $a |
has non-zero size |
|
|
| -b $a |
is a block special |
| -c $a |
is a character special |
| -d $a |
is a directory |
| -f $a |
is a plain file |
| -p $a |
is a named pipe (fifo) |
| -S $a |
is a socket |
| -l $a |
is a symbolic link |
| -t $a |
is a opened to a tty |
| -T $a |
is a text file |
| -B $a |
is a binary file |
|
|
| -u $a |
has setuid bit set |
| -g $a |
has setgid bit set |
| -k $a |
has sticky bit set |
|
|
| -M $a |
Age of file (at startup) in
days since modification (floating) |
| -A $a |
Age of file (at startup) in
days since last access (floating) |
| -C $a |
Age of file (at startup) in
days since inode change(floating) |