Closed fireattack closed 1 year ago
The modified time was managed by the browser or the file system, extension can't specify them.
This feature might be related to #55 . Feel free to share you ideas!
Thanks.
As soon as we can add datetime to the filename (after #74), I can at least use a local script to modify them in batch, so not a big deal (which is also to say that timestamp is definitely not useless in filename).
I will add some pattern tokens in next patch.
Can you share the scenario how do you use the timestamp in filename? In the most of file system, the modified time would be managed by system.
You can always modify them manually:
Like in Python:
from os import utime
from datetime import datetime
from pathlib import Path
def update_mtime(f, mtime=None):
f = Path(f)
if mtime is None:
mtime = datetime.now()
current_mtime = datetime.fromtimestamp(f.stat().st_mtime)
print(f'{f.name}: {current_mtime.isoformat()} -> {mtime.isoformat()}')
mtime_unix = int(mtime.timestamp())
utime(f, (mtime_unix, mtime_unix))
(You can even modify creation time, but that's more complicated.)
Tweet time pattern was introduced in v4.1.5
.
Is your feature request related to a problem? Please describe.
Set the modified time of downloaded items to its tweet time.
Additional context
It is very useful to manage large amount of medias. You can sort by filename to group files by username and sort by modified date to order them in chronological order.
I don't know if it's even possible with download API, though.