Created
April 13, 2011 15:12
-
-
Save steinar/917711 to your computer and use it in GitHub Desktop.
Convert modified PGF (pgf/tikz) files to PDF
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
#!/bin/sh | |
# Convert modified PGF (pgf/tikz) files to PDF | |
pgfTemplate="template.pgs"; | |
echo "Updating modified PGF files:" | |
for path in $(find . -iname "*.pgf") | |
do | |
pgfPath=`dirname $path`/`basename $path pgf`pdf; | |
if [ ! -e $pgfPath ] || [ $path -nt $pgfPath ]; then | |
echo $pgfPath; | |
pgfContents=`cat $path`; | |
replace "<>" "$pgfContents" < $pgfTemplate | rubber-pipe -d > $pgfPath; | |
fi; | |
done; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment