2

One of my colleague is suddenly getting sick seriously and I need to finish his part, so knowing what he is working on most recently would be useful...

For example, if I want to see the most recent files Bob has worked on(or in other words, he modified them most recently) and then sort them by the time. Is there an easy way to do this?

6

You can find out when a file was modified, and you can find out who owns it, but there's no guarantee that the owner is the one who modified it. Write permission can be granted to other users, and there's usually no record of who modified a file. I said "usually" because there is an audit system that can keep that kind of record, but it's not activated in a typical installation.

If you are willing to approximate "files recently modified by bob" using "files owned by bob and recently modified by someone", then

find somedir -type f -user bob -mtime -7 -print

would get you 7 days worth. Maybe if you're only interested in files in bob's home directory, you could omit the -user bob test.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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