Created
November 9, 2017 18:45
-
-
Save wes-goulet/6f2573e5e430f3ea9aacb89547020f15 to your computer and use it in GitHub Desktop.
Converts all .svg files to .pdf files using Inkscape in the current directory
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/env bash | |
svgFiles=$(ls -d -1 $PWD/*.svg) | |
for file in $svgFiles | |
do | |
pdfName=${file/".svg"/".pdf"} | |
echo "Converting $file to $pdfName" | |
/Applications/Inkscape.app/Contents/Resources/bin/inkscape --without-gui --file=$file --export-pdf=$pdfName | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment