I want find
a list of .gif files, convert
them all to series of png
images with filename identifiers and loop those series in this LaTeX.
I am thining here how to combine the find
+ convert
.
I can list .gif file by :
find -L *.gif -type f
I can convert .gif image to a series of png images BUT without own identifier
# TODO take filename from find list and give to convert and to the resulted filename convert -coalesce giphy.gif out%05d.png
Pseudocode where {}.png
tries to say that take the new filename from the list of filenames but I think it cannot work because the list contains also .gif
extension so it should be removed :
find -L *.gif -type f -exec convert -coalesce {} {}.png +
OS: Debian 8.7
find -L . -name '*.gif' -execdir sh -c 'for f; do convert -coalesce "$f" "${f%.gif}%05d.png"; done' sh {} +
– steeldriver Jun 8 '17 at 23:56-execdir
here? - - So you apply a sh loop on a gif image for each list image. Yes, that seems to be correct. - - Do you have any proposal how to find the image series info now to LaTeX and loop it in the linked LaTeX code. – Léo Léopold Hertz 준영 Jun 9 '17 at 4:09