From 3027d36ebb5df030c1898fe8f3b7d09c1c4235f4 Mon Sep 17 00:00:00 2001 From: Simon Michael Date: Mon, 27 Sep 2021 12:15:09 -1000 Subject: [PATCH] ;doc: orgfiles: disable smart dashes in another way Use an org export setting in BACKLOG.org and ROADMAP.org to disable -- being converted to dashes. Leave the markdown+smart workaround in Shake.hs also, it's doing no harm and seems useful as backup. ':nil would disable smart quotes as well, but that seems to be org's default. --- BACKLOG.org | 2 +- ROADMAP.org | 1 + Shake.hs | 10 ++++++---- 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/BACKLOG.org b/BACKLOG.org index 8fbede695..cd9ef8c4c 100644 --- a/BACKLOG.org +++ b/BACKLOG.org @@ -1,5 +1,5 @@ * BACKLOG.org -#+OPTIONS: H:2 +#+OPTIONS: H:2 -:nil An efficient public store of tasks/changes/design notes, mostly from SM's private backlog; things that I/we feel would be nice to have, or diff --git a/ROADMAP.org b/ROADMAP.org index 5b5a36927..b1f93b3ef 100644 --- a/ROADMAP.org +++ b/ROADMAP.org @@ -1,4 +1,5 @@ * ROADMAP.org +#+OPTIONS: -:nil Ideas about where the hledger project should be going next. Being listed here suggests a bit of commitment, perhaps even a schedule. diff --git a/Shake.hs b/Shake.hs index 7a2e9bd2f..9532c4937 100755 --- a/Shake.hs +++ b/Shake.hs @@ -124,8 +124,9 @@ grep = "grep -E" fromsrcmd = "-f markdown-smart-tex_math_dollars" -- The kind of org markup used in any org source files. --- As of pandoc 2.14, org reader always enables smart and -smart has no effect here --- (but writing to markdown+strict will help, undoing the smart typography). +-- In pandoc 2.14, org reader enables smart dashes by default; +-- use #+OPTIONS: -:nil in the org file to disable it (-smart here has no effect). +-- We also write to markdown+strict, which would undo any smart dashes or quotes). fromorg = "-f org-smart" -- The kind of markdown we like to generate for the website. @@ -135,9 +136,10 @@ fromorg = "-f org-smart" -- -- --markdown-headings=atx requires pandoc 2.11.2+; with older pandoc use --atx-headers instead. -- --- +smart here because "If you are writing Markdown, then the smart extension has the +-- In pandoc 2.14, "If you are writing Markdown, then the smart extension has the -- reverse effect: what would have been curly quotes comes out straight.". --- This fixes the unwanted smart typography in org docs (see above). +-- So +smart here can fix unwanted smart typography that may have crept in, +-- eg from org docs (see above). -- towebmd = "-t markdown+smart-fenced_divs-fenced_code_attributes-simple_tables-multiline_tables-grid_tables-raw_attribute --markdown-headings=atx"