aboutsummaryrefslogtreecommitdiff
path: root/md.bqn
diff options
context:
space:
mode:
authorMarshall Lochbaum <mwlochbaum@gmail.com>2020-07-18 23:00:43 -0400
committerMarshall Lochbaum <mwlochbaum@gmail.com>2020-07-18 23:00:43 -0400
commit7b36cd6a7a6d576c19c60e7842a0d0d0c460702a (patch)
tree8c66983cc29babe5f24df783dab1db879b802ebc /md.bqn
parent2366e5a6275d39c1bd9cab2ada26bea00394820d (diff)
Add links to html versions at the top of markdown files
Diffstat (limited to 'md.bqn')
-rw-r--r--md.bqn4
1 files changed, 4 insertions, 0 deletions
diff --git a/md.bqn b/md.bqn
index 85684053..ee79c49f 100644
--- a/md.bqn
+++ b/md.bqn
@@ -292,6 +292,10 @@ Markdown ← {π•Šπ•©:1π•Šπ•©; extensionsπ•Šπ•©:
######
# Create the block structure using line classifications.
+
+ # First remove the html link line: the output *is* the html file.
+ 𝕩 ↩ 2βŠΈβ†“βŸ("*View this file" (⊣ ≑ βŒŠβ—‹β‰ β†‘βŠ’) βŠ‘) 𝕩
+
lengths ← β‰ Β¨ 𝕩 # Length of each line
blanks ← (Lead ' '⊸=)Β¨ 𝕩 # Number of leading blanks
nonEmptyMask ← blanks < lengths # Empty ←→ all leading blanks