I've looked at this question, and while it works there a few issues:
- All converted images are placed in the directory from which the command is called.
- The original images are kept.
I need to convert around 70,000 .tif and .jpgs to .pngs. It's really important the the files when converted are placed in their normal directories.
I can do a batch rm of .tff/.jpg's at the end if that's the best way to handle removing the old files.
basename: invalid option -- 's' Try `basename --help' for more information.
A lot of times...
– user2757729 Jan 16 '14 at 17:01basename
has a-s
option in Ubuntu. Are you sure you are on Ubuntu? – gertvdijk Jan 16 '14 at 17:02basename --suffix=.jpg $f
orbasename $f .jpg
– user.dz Jan 16 '14 at 17:05find -iname
findsfoo.JPG
too - but thebasename $f .jpg
does not handle that. – Volker Siegel Sep 25 '14 at 11:32