HackerReposA FIELD GUIDE TO OPEN SOURCE
ProSponsor the shelf♧ 0
← Back to top all-time
kragen
dercuano
Python2020–2025
kragen / dercuano

dercuano

a quick system I hacked together to bundle a few thousand pages of notes I mostly haven’t published before up into an archive of pregenerated HTML

2Distinct people
4Mentions
0Explicit recommenders
15GitHub stars
REPOSITORY AT A GLANCE

What to know before exploring

What it is

a quick system I hacked together to bundle a few thousand pages of notes I mostly haven’t published before up into an archive of pregenerated HTML

GitHub

Where it is used

No documented product use has been verified yet.

What people are saying

No recommendation phrase was found in the indexed comments.

No classified warning is attached to this page. Read the discussions before treating silence as approval.

Also in these discussions

No other repository is repeatedly linked in the same discussions.

This week on Hacker News

Nov 7–Nov 14 UTC · Direct repository links and separately labeled related project stories. Indexed through 11/14/2026, 5:04:57 PM UTC.

No direct repository links were found in the indexed HN discussions over the past seven days. Older discussions are available below.

Mentions over time

HN mentions by year4 dated mentions

Observed mentions: 2020-01-03 14:54:03 UTC to 2025-10-01 19:50:02 UTC.

0122020-01-01 00:00:00 UTC to 2021-01-01 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 comments20202021-01-01 00:00:00 UTC to 2022-01-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2022-01-01 00:00:00 UTC to 2023-01-01 00:00:00 UTC (exclusive): 2 mentions; 0 submissions, 2 comments20222023-01-01 00:00:00 UTC to 2024-01-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2024-01-01 00:00:00 UTC to 2025-01-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2025-01-01 00:00:00 UTC to 2026-01-01 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 comments2025

Counts come from the repository’s dated source evidence. Index cutoff: 2026-11-02 08:16:59 UTC.

View mention counts and date ranges
UTC ranges include their start and exclude their end. Select a period to filter the source evidence.
PeriodStart (UTC)End (exclusive, UTC)MentionsSubmissionsComments
20202020-01-01 00:00:00 UTC2021-01-01 00:00:00 UTC101
20212021-01-01 00:00:00 UTC2022-01-01 00:00:00 UTC000
20222022-01-01 00:00:00 UTC2023-01-01 00:00:00 UTC202
20232023-01-01 00:00:00 UTC2024-01-01 00:00:00 UTC000
20242024-01-01 00:00:00 UTC2025-01-01 00:00:00 UTC000
20252025-01-01 00:00:00 UTC2026-01-01 00:00:00 UTC101

What Hacker News says

4 sources
Most recently I used ReportLab for direct PDF writing from Python¹, but generating them from PostScript is often easier², depending on what you're doing. https://en.wikipedia.org/wiki/PDF#External_links has a lot of information; also the "Further reading" section has some links which Adobe has broken at the moment, but archive.org versions of them like https://web.archive.org/web/20200127173721/https://www.adobe... work. Also I think Adobe put PDF 1.7 on the Archive themselves: https://archive.org/details/pdf1.7 The ReportLab APIs mirror the PDF file structure relatively closely. Don't listen to the people who are nattering on about how PDF is proprietary on purpose. I think that may have been the case in its early years but it hasn't been the case this millennium. PDF 1.7 (the spec from 02008) and even earlier verions are most often
Read the rest
used, as you'll see if you run head -1 *.pdf in a directory with a lot of random PDFs. PDF 2.0 is not important and you may want to intentionally write an earlier version for broader compatibility. The big incompatibility is actually PDF 1.5 to 1.6: 1.6 added compressed object streams, and a lot of readers still don't support those. ______ ¹ https://github.com/kragen/dercuano/blob/master/genpdf.py ² http://canonical.org/~kragen/sw/laserboot/Makefile
In Ask HN: Why is the PDF format so inaccessible?
I just did something similar. Maybe others will benefit from my experience. For Dercuano I mostly just used Markdown (in Emacs and occasionally Vim, with Git) but then at the end I wrote a janky HTML renderer that outputs PDF in order to have a format people can read on cellphones. If I hadn't done such a rush job on the HTML renderer, I think it would have come out pretty well. A couple of aspects that did work well were Latin Modern Mono Condensed Light (lmtlc), a TeX font derived from Computer Modern Teletype, page-number links, and Reportlab. lmtlc made it possible to produce a PDF that can display 80 columns of fixed-pitch text on a cellphone screen at a readable size, although I had to fall back to FreeMono for characters outside lmtlc’s repertoire and for boldface. And page numbers make it possible to follow links in Google Drive’
Read the rest
s inept PDF viewer, which otherwise lacks any such ability and is disappointingly the Android default, with about 15 seconds of focused effort. Not great, but not bad for a 3700-page book. And Reportlab, a PDF output lib for Python 2, is just a pleasure to work with, which is a phrase very rarely found near the word “PDF”. The PDF renderer is at https://github.com/kragen/dercuano/blob/master/genpdf.py but probably it would have been a better use of time to figure out how to do it in pandoc, which has an actual box model, even though Petersen isn't enthusiastic about his experience with it. Readability on cellphone screens is really difficult, demanding a lot of compromise, and I'm very happy with what I was able to achieve there. With another couple of days I would have added hyphenation and justification, which would have made it considerably better still. The result is at http://canonical.org/~kragen/dercuano.20191230.pdf.
In How to Write a Book in Emacs (2015)

MAKE YOURSELF AT HOME

A few shortcuts

/
Search the collection
?
Open this guide
Esc
Close dialogs and navigation

Your saved repositories and interests stay in this browser.