Add date stamp to filenames of photos by Sony Xperia camera app

(setopt CSH_NULL_GLOB; cd /path/to/Camera\ Uploads; for i in DSC_* MOV_*; do mv -v $i "$(date +%F -d @$(stat -c '%Y' $i)) $i"; done)
Sony's Xperia camera app creates files without time-stamped names. Thus, after deleting files on the phone, the same names will be reused. When uploading the photos to a cloud storage, this means that files will be overwritten. Running this command after every sync of uploaded photos with the computer prevents this.
Sample Output
'DSC_0075.JPG' -> '2020-04-11 DSC_0075.JPG'
'DSC_0076.JPG' -> '2020-04-11 DSC_0076.JPG'

1
By: langec
2020-04-12 06:15:07

What Others Think

Thanks for the solution to this command. I have been searching for this from the last few days.
NelsonFAnderson · 31 weeks and 3 days ago
I have been looking for this command from a few days and didn't find any luck until I landed on this website. I really like this website and it also helps me with my programming assignments that I do with the help ofessaywriting.net.nz/assignment-help-nz. I really like their services and would suggest them to anyone who needs writing assistance.
Fiself1944 · 31 weeks and 3 days ago
The apps and tracking 1-5 devices on an iPhone are simply gorgeous. I can’t imagine having the smartphones of today fifteen years ago as a journalist when I was carting around armloads of equipment to get the spy messages I can get today with a 2019 smartphone. And I would not have such unique powers without the help of https://www.hoverwatch.com/ and their professionalism.
WalterDeversar · 28 weeks ago
the article is soo nice the cloud computing for the port is so good have touch with gbwhatsapp apk
moksha456 · 27 weeks and 6 days ago
Thanks for the detailed information about this. I would love to see more such awesome blog posts from you. Keep up the Good Work! Can someone tell me which version of whatsapp is better? Gbwhatsapp and Fmwhatsapp apk are the best?
immortalGoku1452 · 20 weeks and 2 days ago
Hi, thanks for your information. It's very detailed and usefull.
adamjoseph · 18 weeks and 3 days ago
Hi, thanks for your information. It's very detailed and usefull.
adamjoseph · 18 weeks and 3 days ago
The apps and tracking 1-5 devices on an iPhone are simply gorgeous. I can’t imagine having the smartphones of today fifteen years ago as a journalist when I was carting around armloads black friday vpn deals
adamjoseph · 17 weeks and 6 days ago
Oh, this really works to add a date stamp to filenames of photos by Sony Xperia camera app. This code is really working for me. What about you guys? Have you tried this method? If this, then please raise your hand. CBD Dosage
charlly · 13 weeks and 3 days ago
Great article. Thanks for sharing https://gta5cheats.co
astin082020 · 13 weeks ago
Hi! I had the same problem problem
tomharris · 10 weeks and 5 days ago
I have a small business and now I'm thinking of developing a soft for it. My comany is going to expand and I'm convinsed that website creation and software development for small business plays an important role in its future success. What is your opinion on this topic? Thanks in advance!
tomharris · 10 weeks and 5 days ago
I can tell you about the applications. Because rocking somewhere is delusional and just a loss of money in fact, if you decide to rock for a fee. I can say from myself that the best way would be to go to professionals and download for example on play market . There you can already know for sure that there will be no problems with quality applications and there will be no need to lose money on it. So be sure to get acquainted, for example, I hope that it will be really useful for you now. I hope that someone will be able to help. Good luck!
Manicopus · 10 weeks and 2 days ago
One day, I came and tried to suppress my breath, and I was sad to drink to kill time. 1v1 lol slope unblocked
leschrapid · 9 weeks and 6 days ago
When I read this article, I got some details of how to add a date stamp to filenames of photos by Sony Xperia camera app. You gave a detailed description of this topic, and easy to understand it. Anyway, thanks for sharing the post, ad it is effective too. CBD facts
ryanbabraham · 6 weeks and 1 day ago
great content! will recommend this site to my friends breast implants cleveland
looneyhans · 5 weeks and 4 days ago
nice breast implants cleveland
looneyhans · 5 weeks and 4 days ago
Oh great and this article helpful for everyone. But I have some questions about this app and in my free time, I will ask. Now I am reading information about cheap app developers in Kenya because I have need some development information. I hope so, I will know soon about this.
KennethIWilliams · 2 weeks and 2 days ago
I had been searching for the answer, but unfortunately did not find a right solution. Do you know how much does an http://vote.sparklit.com/comments.spark?contentID=645948&action=viewTopic&commentID=31103554&pollID=645319>on-demand delivery app development cost? I think that the popularity of the development of such apps during the pandemics has become higher. Its demand has risen in parrallel with the high demand for fitness, healthcare and online shopping apps.
tomharris · 1 week and 5 days ago
I had been searching for the answer, but unfortunately did not find a right solution. Do you know how much does an on-demand delivery app development cost? I think that the popularity of the development of such apps during the pandemics has become higher. Its demand has risen in parrallel with the high demand for fitness, healthcare and online shopping apps.
tomharris · 1 week and 5 days ago
thanks for this sandblastingorlando.net
looneyhans · 1 week ago
thanks for this lovely and very cool article! weddingphotographerswichitaks.com
Killersmile · 4 days ago

What do you think?

Any thoughts on this command? Does it work on your machine? Can you do the same thing with only 14 characters?

You must be signed in to comment.

What's this?

commandlinefu.com is the place to record those command-line gems that you return to again and again. That way others can gain from your CLI wisdom and you from theirs too. All commands can be commented on, discussed and voted up or down.

Share Your Commands



Stay in the loop…

Follow the Tweets.

Every new command is wrapped in a tweet and posted to Twitter. Following the stream is a great way of staying abreast of the latest commands. For the more discerning, there are Twitter accounts for commands that get a minimum of 3 and 10 votes - that way only the great commands get tweeted.

» http://twitter.com/commandlinefu
» http://twitter.com/commandlinefu3
» http://twitter.com/commandlinefu10

Subscribe to the feeds.

Use your favourite RSS aggregator to stay in touch with the latest commands. There are feeds mirroring the 3 Twitter streams as well as for virtually every other subset (users, tags, functions,…):

Subscribe to the feed for: