Live data from Hacker News

I built a Git-tracked book production pipeline

djspeckhals.com

51–60 of 95 posts

Re: I built a Git-tracked book production pipeline

#51

As someone who worked for years in commercial print, before most manufacturing moved overseas, I recall the workflows the article discusses as being more automate-able than the author seems to understand. For example, "Making the slightest change became a chore. [1.] Update the 'master' DOCX. [2.] Update the InDesign file ..." --the appropriate way to use an external document as master in InDesign is to use the Place…

The place command does not autoupdate. At least not in the most recent version. Text is either embedded, in which case it's baked in, or linked, in which case you have to manually tell ID to update the link to reload the text. But InDesign's EPUB output is horrifically terrible, especially if you're trying to use custom fonts/graphics for page headings. (Basically - no.) And the CSS is... really not great. The best f…

Yeah, OP’s answer tells me why the big publisher’s EPUB books have always been subpar.

Re: I built a Git-tracked book production pipeline

#52

As someone who worked for years in commercial print, before most manufacturing moved overseas, I recall the workflows the article discusses as being more automate-able than the author seems to understand. For example, "Making the slightest change became a chore. [1.] Update the 'master' DOCX. [2.] Update the InDesign file ..." --the appropriate way to use an external document as master in InDesign is to use the Place…

Hi, OP here. I'm glad you enjoyed the writeup.

Amateur...you're probably right. It reminds me of my home improvement project I've been working on this evening: interior painting. My ceiling lines are probably perfect to houseguests (if they notice at all). But if a professional painter got up on a ladder and looked closely, he'd probably shake his head and chuckle.

As for InDesign and EPUB, I've found the auto-generated output not up to the standard I was after. Worse, I've seen output differ between InDesign versions, which scared me.

I have an acquaintance who works for a "Big 5" publisher, and he recounted their process to me once. In short, the indd file became the source of truth. They would generate an EPUB from it but then hand edit it for many hours to bring it up to their house style. If there was a text change (rare in fiction) they update the indd and EPUB separately. Going back to the Word file is basically non-existent. If the author, copyeditor, proofreader had more extensive changes (like a full revision), it was close to a brand new publication.

The visual styling from the word processer isn't interesting. It's the "tagging" that paragraph and character styles bring that's helpful. It's not dissimilar from an HTML class, which scripting can transform into truly semantic text. I hope that clarifies some points. BTW, it's pretty cool to hear from people in the real print industry. I'm always fascinated by their workflows.

Re: I built a Git-tracked book production pipeline

#53
post #16

Earlier quoted context omitted.

> Overall, as a technical writeup I enjoyed the article; however, I would caution that the author seems to approach publishing from an amateur perspective. I also worked at a publishing company (for ~6 years) in the early 2000s. While you are right that the pros have some tricks to make the process easier, the fact remains that the process is not easy at all. Unlike in academic publishing, where nothing stands betwee…

I did't know what widows and orphans are so I looked it up. > Widow (sometimes called orphan) > Orphan (sometimes called widow) > Runt (sometimes called widow or orphan) Yeah I'm glad we programmers are not the only ones bad at naming things... [0]: https://en.wikipedia.org/wiki/Widows_and_orphans

Yes! All the typographical techniques and terminology is fascinating (and confusing at times). Widow and orphan control really fight against text justification. Finding the right balance is tricky, but LaTeX has all the little knobs to tweak and find what's right for your uses (fiction for me).

Re: I built a Git-tracked book production pipeline

#54
post #38

I've been making ebooks for a nonprofit using typst and pandoc for a few years and it works quite well. We generate a pdf ebook, a print version, and a epub. They each have little tweeks but are all defined conditionally using sys.input. It was rough at first and I've had to open around a dozen or so issues for pandoc to improve things. Now it's pretty seamless.

I saw typst in my explorations but LaTeX had a few more of the controls I was looking for in print, and I really wanted a Standard Ebooks compliant EPUB. I might revisit at some time though. Thanks for bringing it up.

Re: I built a Git-tracked book production pipeline

#55

Setting up good book publishing pipelines with version control + CI/CD might sounds simple, but I don't think it's trivial. One of the best examples of this that I've ever seen is The Sourdough Framework [0] -- really impressed with the way that versioning and publishing is integrated in that book. And yes -- I know it sounds like yet another Javascript library -- but it's actually a book about sourdough bread making…

This was an early inspiration for me that I failed to mention in the article. I'm glad you mentioned it. It really does have a lot of good examples, especially the complex lists and diagrams it implements in TeX.

Re: I built a Git-tracked book production pipeline

#56

Did the author create the Christian novellas he's mentioned? Can't tell by the phrasing. That would be impressive enough on its own, combined with the tech stack?

Author here. Yes, I wrote the books and glued everything together. If I failed to mention it in the article, it's because I was trying not to self-promote so much. Thanks for the compliment. It really was fun to figure it all out, if that wasn't clear :)

Re: I built a Git-tracked book production pipeline

#57
post #6

AKA what CS PhD students have been doing ~forever. I guess this is like medical researchers "discovering" basic calculus or an office worker discovering that SFTP, sshfs, and git work fine and they don't need Dropbox after all. What's common knowledge in one field can apparently still be alien to people outside the field, even in the age of LLMs. Just wait until the author finds out about Overleaf...

Author here. You're exactly right. All of my pre-grad education was liberal arts. I had never once heard of LaTeX until I entered the software world years later, and even then only from a coworker with a CS PhD.

Re: I built a Git-tracked book production pipeline

#58
I enjoyed using Asciidoctor to write a book. It necessitates using a text editor instead of a word processor so it doesn't fit DJ's use case, but it really is quite nice.

I'm also fascinated by the build for Ada & Zangemann, a FOSS illustrated full-color children's book. It looks rather complex, but it handles translations, beautiful typesetting, and was remarkably fast when I tried running the build locally.

Re: I built a Git-tracked book production pipeline

#59

My only problem using git and a text editor is deciding whether I want hard or soft wraps. Vim handles hard wraps better IMO and you can change the git diff engine to something like difft, which makes it much more bearable than the default for hard wrap prose. But softwrap definitely has its advantages: no hard line breaks makes copying the text into other mediums easier, git diffs show only which paragraphs you edit…

I use VS Code soft-wrapping, and `git diff --word-diff` does all I need, though there probably are better methods.

Re: I built a Git-tracked book production pipeline

#60
post #22

Uhm why not Typst? I published my thesis and another book in it and it worked great. They are also working on HTML output which should make it easier to create EPUBs. Until then Pandoc should work I think

typst is great. I experimented with it, it I simply didn't have the fine-tuning and maturity LaTeX. For example, window/orphan control is a binary on/off, while LaTeX calculates by penalties at a much lower level. Pandoc is also great (I used it often for unrelated workflows), but it can't map custom styles from ODT files (not sure about Word).
Post reply on HN