The manpage of ls says:
-u with -lt: sort by, and show, access time; with -l: show access time and sort by name;
otherwise: sort by access time
but that doesn't seem to work:
test@debian:~$ date > file
test@debian:~$ date
Sun Jan 17 13:21:12 CET 2016
test@debian:~$ cat file
Sun Jan 17 13:20:10 CET 2016
test@debian:~$ ls -lu file
-rw-r--r-- 1 test test 29 Jan 17 13:21 file
test@debian:~$ date
Sun Jan 17 13:22:02 CET 2016
test@debian:~$ cat file
Sun Jan 17 13:20:10 CET 2016
test@debian:~$ ls -lu file
-rw-r--r-- 1 test test 29 Jan 17 13:21 file
One should expect instead (since the last access time was at 13:22 or later) something like:
-rw-r--r-- 1 test test 29 Jan 17 13:22 file
What is the explanation? Is the file buffered?