My friend recently asked me for help with a common problem: they needed to upload files to a remote server, but didn’t want to upload everything—just the files that had changed today. Manually checking modification dates for dozens of files? Not fun.

So I wrote a quick Python script to solve it.

The Problem

When you’re syncing files to a remote server, uploading everything is inefficient and time-consuming. You really only need the files you’ve modified today—whether that’s code you’ve been working on, documents you’ve edited, or data files you’ve processed.

The Solution

This get_latest_files_by_today() function scans a folder and returns only the files modified today, sorted with the most recent first:

def get_latest_files_by_today(folder_path: str) -> list:

Similar Posts

Loading similar posts...

Keyboard Shortcuts

Navigation
Next / previous item
j/k
Open post
oorEnter
Preview post
v
Post Actions
Love post
a
Like post
l
Dislike post
d
Undo reaction
u
Recommendations
Add interest / feed
Enter
Not interested
x
Go to
Home
gh
Interests
gi
Feeds
gf
Likes
gl
History
gy
Changelog
gc
Settings
gs
Browse
gb
Search
/
General
Show this help
?
Submit feedback
!
Close modal / unfocus
Esc

Press ? anytime to show this help