convert somefile.png somefile.pdf
Which is quite simple, and much better than opening preview -> export2->select pdf-> and hit save. But typing that for more than one image is also tedious. So, I decided I’d better create a service that would essentially do the following.
It would take the selected finder items, mainly images in
jpeg, or whatever, and convert all of them to
The shell script is quite simple. Because the
convert command from Imagemagick is not a command in bash, I have to call it with the whole path. The rest of that one-liner is a
sed call to substitute whatever extension the input file has (with the regex
1 2 3 4 5