Bug#1002501: release-notes: Quotes (" and ') in commands in PDF release notes are "smart" (”*” / ’hold$’) so don't copy/paste
Package: release-notes
Followup-For: Bug #1002501
X-Debbugs-Cc: 1002501-submitter@bugs.debian.org
On Thu, 15 Dec 2022 14:01:49 +0100, Paul Gevers wrote:
> The release notes are generated with docbook. I spend about an hour to
> find out how to prevent conversion of straight quotes to curly quotes
Funny how it's sometimes the seemingly-simple fixes that prove the most
infuriating to fix, isn't it? :)
I spent a significantly longer amount of time on this one; I learned fairly
early on that the 'upquote' LaTeX package was a potential fix (thanks to
aerostitch[1] and postgis[2]), but in practice getting that to work with
the PDF documentation generation involved various failed attempts.
However..
In addition to including the 'upquote' package, it seems that a combination of
two additional changes[3] produces the desired result:
* Using single straight quotes instead of double quotes
* Placing the relevant text within a 'screen' docbook element
Fortunately single-quotes is probably a safer and better recommendation anyway
since it's generally less prone to globbing, at least in bash.
(note: I also had to temporarily rename some font filenames[4] locally in order
for the build to succeed when using 'make pdf LINGUA=en architecture=arm64')
[1] - https://aerostitch.github.io/misc/asciidoc/asciidoc-pdf_keep_quotes.html
[2] - https://github.com/postgis/postgis/pull/128
[3] - https://salsa.debian.org/jayaddison/release-notes/-/commit/4922a80e12db746de8bf8cad45d4fe63d43d9f90
[4] - https://salsa.debian.org/jayaddison/release-notes/-/blob/4922a80e12db746de8bf8cad45d4fe63d43d9f90/Makefile#L82-85
Reply to: