Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

When I need to find my recently used files, this command:

ls -lt

lists in ascending order (by time), when there are lots files, I need to scroll to the top to see needed files, because wont fit in terminal screen.

After finding out that tac inverses the output, I use: ls -lt dir/ | tac Is there more fun way of doing it, without using external scripts/utils?

share|improve this question

1 Answer 1

The -r does the same thing for ls as tac does for any command which needs reverse file ordering.

So you could just write

ls -ltr
share|improve this answer
Thanks! Used ls for ages and never new there's -r :p –  linux-newbie Nov 7 '12 at 18:46
This is remembered with the handy mnemonic "later". As in, "I want to see the files that were changed later: ls -ltr" –  bahamat Nov 7 '12 at 20:16
Its also sad because in most other popular commands it stands for 'recursive'... –  dolzenko Sep 10 '14 at 20:59

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.