Find Files Modified On A Specific Day

In today’s article, we’re going to do exactly what the title says, we’re going to find files modified on a specific day. Imagine that! We’re doing what it says in the title! I dunno why I write the things I do. But, I do have quite a few people reading, and hardly any of ’em complain!

So, why would you want to do this? Well, let’s say Big Bad John logged into your system on Friday. He was fired for drinking at lunch, but still had access to the system for another hour before security got around to hauling his butt out of the building.

Wouldn’t you like to know what files were changed on his computer that day, just to see if he’d done anything malicious? You might also have some weird system errors and want to know what files have changed today so that you can narrow down your search for the culprit. There are all sorts of reasons why you might want to know how to find files modified on a specific day.

We’re going to be using a simple command, and just one command. We’ll be using the ‘find’ function. There are surely other ways to do this, but we’ll use the find command. It works and it means you have a relatively short article.

How To: Find Files Modified On A Specific Day:

This article requires an open terminal, like many other articles on this site. If you don’t know how to open the terminal, you can do so with your keyboard – just press CTRL + ALT + T and your default terminal should open.

With your terminal now open, let’s say you want to find files edited on the day this article is published. To do that, you’d run this command:

For the sake of simplicity, the format is YYYY-MM-DD. You could use other date formats that are recognized by the system, but we’ll just stick to this date format as it’s nice and easy.

Now, you can also adjust your ‘maxdepth‘ value. If it’s a 1, it will dig down one directory deep. So, if you’re in your home directory, it’ll dig into ~/Downloads, ~/Pictures, ~/Documents, etc… If you change it to 2, it’ll dig into the sub-directories, like ~/Downloads/foo and ~/Documents/bar.

If you want to find files modified on a specific day, simply change the date in the command and start searching. It’s handy if you edited a file and can’t recall which file it was you edited. The command can be used for all sorts of things like that. Good luck!

Closure:

There you go… You have another article and this one teaches you how to find files modified on a specific day. It’s a short article with just one command. There’s no reason to pad the article further. It’s just the one command. Thanks for reading!

Thanks for reading! If you want to help, or if the site has helped you, you can donate, register to help, write an article, or buy inexpensive hosting to start your own site. If you scroll down, you can sign up for the newsletter, vote for the article, and comment.

Subscribe to Newsletter!
Get notified when new articles are published!
We promise to never share your email!
icon

Author: KGIII

Retired mathematician, residing in the mountains of Maine. I may be old and wise, but I am not infallible. Please point out any errors. And, as always, thanks again for reading.

One thought on “Find Files Modified On A Specific Day”

Leave a Reply

Your email address will not be published. Required fields are marked *

Linux Tips
Creative Commons License
This work is licensed under a Creative Commons Attribution 4.0 International License.