Very nice write up. I use pdfsam (PDF Split And Merge) to combine
multiple PDFs into one. It is a very simple java based GUI that works
well for me.

On 2019-02-13 20:04, Mike Miller wrote: 

> I wanted to buy a music book with the songs from Andrew Lloyd Webber's Jesus Christ Superstar, but the first thing that came up in my search was a web page with 141 SVG files, probably including everything I wanted. But 141 SVG files would be a little inconvenient to work with, so I thought I'd convert them to a single PDF file. There were a few Linuxy tricks to it, so I thought I'd share it here.
> 
> To convert SVG to PDF, I used inkscape...
> 
> sudo apt install inkscape
> 
> inkscape -⁠-⁠without-⁠gui -⁠-⁠file=infile.svg -⁠-⁠export-⁠pdf=outfile.pdf
> 
> ...but that was giving an annoying warning until I ran this:
> 
> sudo apt-⁠get install libcanberra-⁠gtk-⁠module
> 
> Download the 141 SVG files:
> 
> for I in {0..140} ; do wget -⁠nv https://musescore.com/static/musescore/scoredata/gen/1/5/3/3850351/1fc07f50b82c55710a959b344e84619dc45b25be/score_${I}.svg [1] ; done
> 
> Use inkscape to convert the SVG to PDF, preserving the vector format:
> 
> for I in {0..140} ; do echo -⁠ne "$I\r" ; inkscape -⁠-⁠without-⁠gui -⁠-⁠file=score_${I}.svg -⁠-⁠export-⁠pdf=score_${I}.pdf ; done
> 
> We can remove the SVG files:
> 
> rm score_*.svg
> 
> zero-pad the numbers in the PDF filenames so that they are in proper order for globbing in the pdfunite command:
> 
> rename 's/⁠_(\d)\./⁠_0$1\./⁠' score_?.pdf
> rename 's/⁠_(\d\d)\./⁠_0$1\./⁠' score_??.pdf
> 
> To combine the 141 PDF files into one 141-page PDF, I tried pdftk first, but it was failing with errors, so I used pdfunite from the poppler-utils package. If you don't have pdfunite, you can install it:
> 
> sudo apt install poppler-⁠utils
> 
> pdfunite score_*.pdf Jesus_Christ_Superstar.pdf
> 
> Now we can remove the individual PDF files:
> 
> rm score_*.pdf
> 
> I'm glad I discovered pdfunite. It's easier to use than pdftk for merging and it worked where pdftk failed.
> 
> Best,
> 
> Mike
> _______________________________________________
> TCLUG Mailing List -⁠ Minneapolis/⁠St. Paul, Minnesota
> tclug-list at mn-linux.org
> http://mailman.mn-linux.org/mailman/listinfo/tclug-list [2]
 

Links:
------
[1]
https://musescore.com/static/musescore/scoredata/gen/1/5/3/3850351/1fc07f50b82c55710a959b344e84619dc45b25be/score_${I}.svg
[2] http://mailman.mn-linux.org/mailman/listinfo/tclug-list
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.mn-linux.org/pipermail/tclug-list/attachments/20190227/5441f18c/attachment.html>