Created
January 14, 2019 14:25
-
-
Save cwlls/74d7c7fca86a6b411019985cc7d5dbf6 to your computer and use it in GitHub Desktop.
Rename files downloaded from Arlo (Netgear) to something more parsable by humans
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
import os | |
import sys | |
import datetime as datetime | |
for file in os.listdir(sys.argv[1]): | |
ts = datetime.fromtimestamp(float(os.path.splitext(file)[0])/1000.0) | |
os.rename(file, ts.strftime("%m%d%Y-%H%M%S.mp4")) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment