Problem :
I’m on lubuntu and I accidentally moved a folder into another folder in my home folder. It happened in half a second while brushing against the touchpad. How do I find out what file moved where?
Solution :
The command
find /pth/to/dir -type f -mmin -60
will show you all files inside /path/to/dir
and all of its subdirectories which have been modified in the last 60
minutes.
If you want to search for something less recent,
find /path/to/dir -type f -mtime -2
will displayed the files modified in the last 2 days.
The command
find /path/to/dir -type f -mtime -5 ! -mtime -2
will display files modified in the last 5 days, execpt for those modified in the last two days.
The command
find /path/to/dir -type f -mtime -5 -exec ls -al {} ;
will find files modified within the last five days, and will do an ls of them, showing may useful properties.