October 30, 2008
Automating PDF Output in Ubuntu
I’ve recently been working with automating the transformation of print streams into pdf files. Ubuntu’s “printer configuration” tool is very handy for setting up custom layout of pdf output. What I did was copy the printer called “PDF” that is the standard generic print-to-pdf printer (cups-pdf) and edited the text options for a custom layout of the text to fit a pre-printed form layout.
I also want to add a barcode into the print file, that has proven to be a little more tricky. I’ve used the barcode package to create barcodes. It outputs a postscript file of the barcode using the following command:
barcode -b barcode_value -ecode39 -n -g300x30 -c -p300x30 > output.ps
Now the part I’m still puzzling over is merging the two into the same page. because in my case I do not want them to just be concatenated together but to be overlayed over each other. I also need to put one of these in the bottom left hand corner of each page of the print document. I think my answer will come from the psutils package. I’m working through the man pages for a couple of tools that will hopefully do the trick. If anyone has any suggestions feel free to let me know.

