joinPdf

Word processors, spreadsheets, presentations, translation, etc.
Message
Author
disciple
Posts: 6984
Joined: Sun 21 May 2006, 01:46
Location: Auckland, New Zealand

#31 Post by disciple »

I'm using pdfunite from poppler
Even though they're both java based, I was thinking about the possibility of instead using sejda (command line version of pdfsam) or pdftk, to create the pdf with bookmarks.
I found that there is now a very similar project which already creates the pdf with bookmarks. It is using gs, so it will have the performance problems I was complaining about, whereas sejda or pdfsam wouldn't.
https://github.com/bronson/pdfdir
Do you know a good gtkdialog program? Please post a link here

Classic Puppy quotes

ROOT FOREVER
GTK2 FOREVER

disciple
Posts: 6984
Joined: Sun 21 May 2006, 01:46
Location: Auckland, New Zealand

#32 Post by disciple »

Hi guys,
I have reworked both scripts a reasonable amount.
Changes include:
- searches for pdfs by mime type rather than file extension (should be more reliable - I assume slower, but it can still join 960 files pretty quickly here!).
- less Puppy specific (gui version doesn't assume rox).
- uses natsort if available, otherwise coreutils `sort -V`, with plain sort as last resort.
- uses pdfunite if available, otherwise gs.
- at least one gui bugfix (I'm rather surprised no one reported the bug - does everybody have the same use pattern as me?).
- gui related error checking, cosmetic enhancements, and ability to enter the program you want to use to view (or postprocess :) ) the output file.
- main gui isn't blocked by the help window or the browser launched to visit this thread).
- better handling of temporary files (multiple instances won't mess with each other, and it should be more portable).
Attachments
Capture2.JPG
(24.77 KiB) Downloaded 528 times
Capture.JPG
(48.9 KiB) Downloaded 549 times
scripts.zip
(6.29 KiB) Downloaded 411 times
Do you know a good gtkdialog program? Please post a link here

Classic Puppy quotes

ROOT FOREVER
GTK2 FOREVER

User avatar
greengeek
Posts: 5789
Joined: Tue 20 Jul 2010, 09:34
Location: Republic of Novo Zelande

#33 Post by greengeek »

Just getting this on my list for testing.

disciple
Posts: 6984
Joined: Sun 21 May 2006, 01:46
Location: Auckland, New Zealand

#34 Post by disciple »

Note in case anyone has an issue with the latest version using gawk to generate the output file name:
Some systems these days may include mawk rather than gawk by default. Mawk seems to work fine, too. In fact I tested it with a busybox awk and on OSX with what I think is the original Unix awk, and it seemed to work everywhere.
So I'm not 100% sure - maybe the awk I had available at the time was some obscure or old crippled implementation, or maybe the internationalisation of gawk helped with accented letters in gjoinpdf or something, or maybe it was unnecessary and it would have worked with plain awk all along.
Do you know a good gtkdialog program? Please post a link here

Classic Puppy quotes

ROOT FOREVER
GTK2 FOREVER

Post Reply