File tree Expand file tree Collapse file tree 2 files changed +6
-5
lines changed Expand file tree Collapse file tree 2 files changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -51,7 +51,7 @@ process_file() {
51
51
sed ' s#<div class="code"><pre>#<pre><code>#g' | \
52
52
sed ' s#</pre></div>#</code></pre>#g' | \
53
53
pandoc -f html-native_divs-native_spans \
54
- -t markdown --wrap=none --atx-headers \
54
+ -t gfm+pipe_tables --wrap=none \
55
55
--lua-filter " ${UTILSPATH} /pandoc_codeblock.lua" | \
56
56
sed ' s/``` {#sh}/```sh/' | sed ' s+ \\\$+ \$+g' | sed ' s+%20+-+g' > " ${f%% .html} .md"
57
57
Original file line number Diff line number Diff line change @@ -7,6 +7,11 @@ local MAX_LINE_LENGTH = 120 -- Adjust as needed for MD013
7
7
8
8
local LIST_INDENT = " "
9
9
10
+ function Str (el )
11
+ local text = el .text :gsub (" %s+$" , " " ) -- Remove trailing spaces
12
+ return pandoc .Str (text )
13
+ end
14
+
10
15
function RawInline (el )
11
16
-- Convert <em> to Markdown italics, and handle special characters
12
17
if el .format == " html" then
@@ -134,10 +139,6 @@ function Table(el)
134
139
return el
135
140
end
136
141
137
- function Str (el )
138
- local text = el .text :gsub (" %s+$" , " " ) -- Remove trailing spaces
139
- return pandoc .Str (text )
140
- end
141
142
142
143
function Header (el )
143
144
return pandoc .Header (el .level , el .content ) -- Ensure ATX-style headers
You can’t perform that action at this time.
0 commit comments