Monday , February 3 2025

How to find changed files in console

Relevant for Linux, macOS. This article lists commands that help you find files that have changed over a certain period.

1. Find all modified files in the current folder in order of freshness of changes. The most recent will be on top:

find ./c -type f -printf '%TY-%Tm-%Td %TT %p\n' | sort -r 

It is more convenient for me to watch without infinite scrolling:

find /etc -type f -printf '%TY-%Tm-%Td %TT %p\n' | sort -r | less

Ahaha, are you trapped and don’t know how to get out? Press q.

2. Find modified files in the current folder for the last hour:

find ./ -type f -mmin -60

3. Find modified files in the current folder for the last 2 days:

find ./ -type f -mtime -2

About iryna

I'm Iryna, a web developer from Ukraine with a decade of experience solving complex technical challenges in the world of freelance. Throughout my career, I've worked on everything from troubleshooting server-side issues and optimizing website performance to enhancing user interfaces. On this blog, I share detailed solutions to the technical problems I’ve encountered and methods that have worked best for me. In addition to my technical expertise, I’m also passionate about digital drawing. I hope the tutorials and insights I provide here will help both fellow developers and creatives alike in their own projects.

Check Also

How to open html pages without .html

If your site uses links like http://domain.com/testpage.html and http://domain.com/demo.html, and you want them to open …

Leave a Reply

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