Debian Codegraph @

org/testdata/misc.html

raw
1 <h1 class="title">Misc title <b>with an inline html export</b></h1>
2 <nav>
3 <ul>
4 <li><a href="#headline-1">issues from goorgeous (free test cases, yay!)</a>
5 <ul>
6 <li><a href="#headline-2">#19: Support #+HTML</a>
7 </li>
8 <li><a href="#headline-3">#29: Support verse block</a>
9 </li>
10 <li><a href="#headline-4">#30: Support #+SETUPFILE</a>
11 </li>
12 <li><a href="#headline-5">#31: Support #+INCLUDE</a>
13 </li>
14 <li><a href="#headline-6">#33: Wrong output when mixing html with Org mode</a>
15 </li>
16 <li><a href="#headline-7">#41: Support Table Of Contents</a>
17 </li>
18 <li><a href="#headline-8">#46: Support for symbols like ndash and mdash</a>
19 </li>
20 <li><a href="#headline-9">#47: Consecutive <code>code</code> wrapped text gets joined</a>
21 </li>
22 <li><a href="#headline-10">#50: LineBreaks in lists are preserved</a>
23 </li>
24 <li><a href="#headline-11">#68: Quote block with inline markup</a>
25 </li>
26 <li><a href="#headline-12">#72: Support for #+ATTR_HTML</a>
27 </li>
28 <li><a href="#headline-13">#75: Not parsing nested lists correctly</a>
29 </li>
30 <li><a href="#headline-14">#77: Recognize <code class="verbatim">code</code>— as code plus dash</a>
31 </li>
32 <li><a href="#headline-15">#78: Emphasis at beginning of line</a>
33 </li>
34 <li><a href="#headline-16">#82: Crash on empty headline</a>
35 <ul>
36 <li><a href="#headline-17"></a>
37 </li>
38 </ul>
39 </li>
40 <li><a href="#headline-18">#84: Paragraphs that are not followed by an empty line are not parsed correctly</a>
41 <ul>
42 <li><a href="#headline-19">Foo</a>
43 </li>
44 <li><a href="#headline-20">Bar</a>
45 </li>
46 </ul>
47 </li>
48 <li><a href="#headline-21">#86: Multiple hyphens not converted to dashes</a>
49 </li>
50 <li><a href="#headline-22">#87: Markup in footnotes is rendered literally</a>
51 </li>
52 <li><a href="#headline-23">#92: src blocks only render in caps</a>
53 </li>
54 </ul>
55 </li>
56 <li><a href="#headline-24">issues (wrongly) filed with hugo</a>
57 <ul>
58 <li><a href="#headline-25">#3874 exporting images in org mode</a>
59 </li>
60 <li><a href="#headline-26">#4006 source code blocks in org not rendered correctly</a>
61 </li>
62 </ul>
63 </li>
64 <li><a href="#headline-27">misc fuzz / regression / edge case</a>
65 <ul>
66 <li><a href="#headline-28">index out of range in headline priority parsing</a>
67 <ul>
68 <li><a href="#headline-29">[#B</a>
69 </li>
70 </ul>
71 </li>
72 <li><a href="#headline-30">index out of range in explicit line break parsing</a>
73 </li>
74 <li><a href="#headline-31">list items don&#39;t end on child headline</a>
75 <ul>
76 <li><a href="#headline-32">followed by a child headline</a>
77 </li>
78 </ul>
79 </li>
80 </ul>
81 </li>
82 <li><a href="#headline-33">Footnotes</a>
83 </li>
84 </ul>
85 </nav>
86 <div id="outline-container-headline-1" class="outline-3">
87 <h3 id="headline-1">
88 issues from goorgeous (free test cases, yay!)
89 </h3>
90 <div id="outline-text-headline-1" class="outline-text-3">
91 <div id="outline-container-headline-2" class="outline-4">
92 <h4 id="headline-2">
93 <span class="todo status-done">DONE</span>
94 <a href="https://github.com/chaseadamsio/goorgeous/issues/19">#19</a>: Support #+HTML
95 </h4>
96 <div id="outline-text-headline-2" class="outline-text-4">
97 <p style="border: 1px dotted grey">neato!</p>
98 </div>
99 </div>
100 <div id="outline-container-headline-3" class="outline-4">
101 <h4 id="headline-3">
102 <span class="todo status-done">DONE</span>
103 <a href="https://github.com/chaseadamsio/goorgeous/issues/29">#29:</a> Support verse block
104 </h4>
105 <div id="outline-text-headline-3" class="outline-text-4">
106 <div class="verse-block">
107 <p>This
108 <strong>is</strong>
109 verse</p>
110 </div>
111 <div class="custom-block">
112 <p>or even a <strong>totally</strong> <em>custom</em> kind of block
113 crazy ain&#39;t it?</p>
114 </div>
115 </div>
116 </div>
117 <div id="outline-container-headline-4" class="outline-4">
118 <h4 id="headline-4">
119 <span class="todo status-done">DONE</span>
120 <a href="https://github.com/chaseadamsio/goorgeous/issues/30">#30</a>: Support #+SETUPFILE
121 </h4>
122 <div id="outline-text-headline-4" class="outline-text-4">
123 <p>see <code class="verbatim">./headlines.org</code></p>
124 </div>
125 </div>
126 <div id="outline-container-headline-5" class="outline-4">
127 <h4 id="headline-5">
128 <span class="todo status-done">DONE</span>
129 <a href="https://github.com/chaseadamsio/goorgeous/issues/31">#31</a>: Support #+INCLUDE
130 </h4>
131 <div id="outline-text-headline-5" class="outline-text-4">
132 <p>Note that only src/example/export block inclusion is supported for now.
133 There&#39;s quite a lot more to include (see the <a href="https://orgmode.org/manual/Include-files.html">org manual for include files</a>) but I
134 don&#39;t have a use case for this yet and stuff like namespacing footnotes of included files
135 adds quite a bit of complexity.</p>
136 <p>
137 for now files can be included as:</p>
138 <ul>
139 <li>
140 <p>src block</p>
141 <div class="src src-org">
142 <div class="highlight">
143 <pre>
144 #+SETUPFILE: setup_file_org
145 #+OPTIONS: toc:1
146 * Simple Headline [1/2]
147 - [X] checked
148 - [ ] unchecked
149 - note that statistic tokens are marked up anywhere
150 not just where they are actually meant to be - even here &gt; [100%] &lt;
151 (Org mode proper does the same)
152 * TODO [#B] Headline with todo status &amp; priority
153 * DONE Headline with TODO status
154 :PROPERTIES:
155 :custom_id: this-will-be-the-id-of-the-headline
156 :note: property drawers are not exported as html like other drawers
157 :END:
158
159 we can link to headlines that define a custom_id: [[#this-will-be-the-id-of-the-headline]]
160 * [#A] Headline with tags &amp; priority :foo:bar:
161 Still outside the drawer
162 :DRAWERNAME:
163 This is inside the drawer
164 :end:
165 Still outside the drawer
166 * CUSTOM headline with custom status
167 it&#39;s possible to use =#+SETUPFILE= - in this case the setup file contains the following
168
169 #+INCLUDE: &#34;setup_file_org&#34; src org
170 * excluded headline :custom_noexport:
171 this headline and it&#39;s content are not exported as it is marked with an =EXCLUDE_TAGS= tag.
172 By default =EXCLUDE_TAGS= is just =:noexport:=.
173
174 * TODO [#A] COMMENT commented headline
175 this headline is commented out. see [[https://orgmode.org/manual/Comment-Lines.html][comment lines]]
176 * malformed property drawer
177 :PROPERTIES:
178 not a property
179 :END:
180 * level limit for headlines to be included in the table of contents
181 The toc option allows setting a [[https://orgmode.org/manual/Export-settings.html][level limit]]. For this file we set it to 1 - which means that the following headlines
182 won&#39;t be included in the table of contents.
183 ** headline 2 not in toc
184 *** headline 3 not in toc
185 ** anoter headline 2 not in toc
186 you get the gist...
187 </pre>
188 </div>
189 </div>
190 </li>
191 <li>
192 <p>export block</p>
193 <p>Paragraphs are the default element.</p>
194 <p>
195 Empty lines and other elements end paragraphs - but paragraphs
196 can
197 obviously
198 span
199 multiple
200 lines.</p>
201 <p>
202 Paragraphs can contain inline markup like <em>emphasis</em> <strong>strong</strong> and links <a href="https://www.example.com">example.com</a> and stuff.</p>
203 </li>
204 <li>
205 <p>example block</p>
206 <pre class="example">
207 name: CI
208
209 on:
210 push:
211 branches: [ master ]
212
213 jobs:
214 build:
215 runs-on: ubuntu-latest
216 steps:
217 - name: git
218 run: |
219 git clone --depth 1 &#34;https://x-access-token:${{secrets.GITHUB_TOKEN}}@github.com/${GITHUB_REPOSITORY}&#34; .
220 git config user.name &#34;GitHub Action&#34;
221 git config user.email &#34;[email protected]&#34;
222 git log -1 --format=&#34;%H&#34;
223 - name: go
224 run: sudo snap install go --classic
225 - name: test
226 run: make test
227 - name: gh-pages
228 run: |
229 git checkout --orphan gh-pages &amp;&amp; git reset
230 make generate-gh-pages
231 git add -f docs/ &amp;&amp; git commit -m deploy
232 git push -f origin gh-pages
233 - name: notify
234 if: ${{ failure() }}
235 run: |
236 text=&#34;https://github.com/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID} failed&#34;
237 curl --silent --output /dev/null ${{secrets.TELEGRAM_URL}} -d &#34;chat_id=${{secrets.TELEGRAM_CHAT_ID}}&amp;text=${text}&#34;
238 </pre>
239 </li>
240 </ul>
241 </div>
242 </div>
243 <div id="outline-container-headline-6" class="outline-4">
244 <h4 id="headline-6">
245 <span class="todo status-done">DONE</span>
246 <a href="https://github.com/chaseadamsio/goorgeous/issues/33">#33</a>: Wrong output when mixing html with Org mode
247 </h4>
248 <div id="outline-text-headline-6" class="outline-text-4">
249 <div class="outline-2" id="meta" style="color: green;">
250 <table>
251 <tbody>
252 <tr>
253 <td><strong>foo</strong></td>
254 <td>foo</td>
255 </tr>
256 <tr>
257 <td><strong>bar</strong></td>
258 <td>bar</td>
259 </tr>
260 </tbody>
261 </table>
262 </div>
263 </div>
264 </div>
265 <div id="outline-container-headline-7" class="outline-4">
266 <h4 id="headline-7">
267 <span class="todo status-done">DONE</span>
268 <a href="https://github.com/chaseadamsio/goorgeous/issues/41">#41</a>: Support Table Of Contents
269 </h4>
270 </div>
271 <div id="outline-container-headline-8" class="outline-4">
272 <h4 id="headline-8">
273 <span class="todo status-done">DONE</span>
274 <a href="https://github.com/chaseadamsio/goorgeous/issues/46">#46</a>: Support for symbols like ndash and mdash
275 </h4>
276 <div id="outline-text-headline-8" class="outline-text-4">
277 <ul>
278 <li>ndash –</li>
279 <li>mdash —</li>
280 <li>ellipsis …</li>
281 <li>acute Á and so on</li>
282 <li>note that —— is replaced with 2 mdashes and …. becomes ellipsis+. and so on - that&#39;s how org also does it</li>
283 </ul>
284 </div>
285 </div>
286 <div id="outline-container-headline-9" class="outline-4">
287 <h4 id="headline-9">
288 <span class="todo status-done">DONE</span>
289 <a href="https://github.com/chaseadamsio/goorgeous/issues/47">#47:</a> Consecutive <code>code</code> wrapped text gets joined
290 </h4>
291 <div id="outline-text-headline-9" class="outline-text-4">
292 <p>either <code>this</code> or <code>that</code> foo.
293 either <code>this</code>
294 or <code>that</code> foo.</p>
295 </div>
296 </div>
297 <div id="outline-container-headline-10" class="outline-4">
298 <h4 id="headline-10">
299 <span class="todo status-done">DONE</span>
300 <a href="https://github.com/chaseadamsio/goorgeous/issues/50">#50</a>: LineBreaks in lists are preserved
301 </h4>
302 <div id="outline-text-headline-10" class="outline-text-4">
303 <ul>
304 <li>this list item
305 has
306 multiple
307 linbreaks - but it&#39;s still just one paragraph (i.e. no line breaks are rendered)</li>
308 <li>foobar</li>
309 </ul>
310 <ol>
311 <li>same
312 goes
313 for
314 ordered
315 lists</li>
316 <li>foo</li>
317 </ol>
318 </div>
319 </div>
320 <div id="outline-container-headline-11" class="outline-4">
321 <h4 id="headline-11">
322 <span class="todo status-done">DONE</span>
323 <a href="https://github.com/chaseadamsio/goorgeous/issues/68">#68</a>: Quote block with inline markup
324 </h4>
325 <div id="outline-text-headline-11" class="outline-text-4">
326 <blockquote>
327 <p><a href="https://www.example.com"><em>this</em> <strong>is</strong> <span style="text-decoration: underline;">markup</span>!</a></p>
328 </blockquote>
329 </div>
330 </div>
331 <div id="outline-container-headline-12" class="outline-4">
332 <h4 id="headline-12">
333 <span class="todo status-done">DONE</span>
334 <a href="https://github.com/chaseadamsio/goorgeous/issues/72">#72</a>: Support for #+ATTR_HTML
335 </h4>
336 <div id="outline-text-headline-12" class="outline-text-4">
337 <img src="https://golang.org/doc/gopher/pkg.png" alt="Go is fine though." title="https://golang.org/doc/gopher/pkg.png" id="gopher-image" width="300" style="border:2px solid black;"/>
338 </div>
339 </div>
340 <div id="outline-container-headline-13" class="outline-4">
341 <h4 id="headline-13">
342 <span class="todo status-done">DONE</span>
343 <a href="https://github.com/chaseadamsio/goorgeous/issues/75">#75</a>: Not parsing nested lists correctly
344 </h4>
345 <div id="outline-text-headline-13" class="outline-text-4">
346 <ul>
347 <li>
348 <p>bullet 1</p>
349 <ul>
350 <li>sub bullet</li>
351 </ul>
352 </li>
353 </ul>
354 </div>
355 </div>
356 <div id="outline-container-headline-14" class="outline-4">
357 <h4 id="headline-14">
358 <span class="todo status-done">DONE</span>
359 <a href="https://github.com/chaseadamsio/goorgeous/issues/77">#77</a>: Recognize <code class="verbatim">code</code>— as code plus dash
360 </h4>
361 </div>
362 <div id="outline-container-headline-15" class="outline-4">
363 <h4 id="headline-15">
364 <span class="todo status-done">DONE</span>
365 <a href="https://github.com/chaseadamsio/goorgeous/issues/78">#78</a>: Emphasis at beginning of line
366 </h4>
367 <div id="outline-text-headline-15" class="outline-text-4">
368 <p><em>italics</em></p>
369 <p>
370 Text
371 <em>italics</em></p>
372 </div>
373 </div>
374 <div id="outline-container-headline-16" class="outline-4">
375 <h4 id="headline-16">
376 <span class="todo status-done">DONE</span>
377 <a href="https://github.com/chaseadamsio/goorgeous/issues/82">#82</a>: Crash on empty headline
378 </h4>
379 <div id="outline-text-headline-16" class="outline-text-4">
380 <div id="outline-container-headline-17" class="outline-5">
381 <h5 id="headline-17">
382
383 </h5>
384 <div id="outline-text-headline-17" class="outline-text-5">
385 <p>just a space as title…</p>
386 </div>
387 </div>
388 </div>
389 </div>
390 <div id="outline-container-headline-18" class="outline-4">
391 <h4 id="headline-18">
392 <span class="todo status-done">DONE</span>
393 <a href="https://github.com/chaseadamsio/goorgeous/issues/84">#84</a>: Paragraphs that are not followed by an empty line are not parsed correctly
394 </h4>
395 <div id="outline-text-headline-18" class="outline-text-4">
396 <div id="outline-container-headline-19" class="outline-5">
397 <h5 id="headline-19">
398 Foo
399 </h5>
400 <div id="outline-text-headline-19" class="outline-text-5">
401 <p>Foo paragraph.</p>
402 </div>
403 </div>
404 <div id="outline-container-headline-20" class="outline-5">
405 <h5 id="headline-20">
406 Bar
407 </h5>
408 <div id="outline-text-headline-20" class="outline-text-5">
409 <p>Bar paragraph</p>
410 </div>
411 </div>
412 </div>
413 </div>
414 <div id="outline-container-headline-21" class="outline-4">
415 <h4 id="headline-21">
416 <span class="todo status-done">DONE</span>
417 <a href="https://github.com/chaseadamsio/goorgeous/issues/86">#86</a>: Multiple hyphens not converted to dashes
418 </h4>
419 <div id="outline-text-headline-21" class="outline-text-4">
420 <p>just like #46</p>
421 <ul>
422 <li><code class="verbatim">--</code> -&gt; – (en dash)</li>
423 <li><code class="verbatim">---</code> -&gt; — (em dash)</li>
424 </ul>
425 <p>also, consecutive dashes inside</p>
426 <ul>
427 <li>inline code <code class="verbatim">--</code> <code class="verbatim">---</code> and verbatim <code>--</code> <code>---</code></li>
428 <li>
429 <p>src/example/export blocks should not be converted!</p>
430 <div class="src src-sh">
431 <div class="highlight">
432 <pre>
433 --, ---
434 </pre>
435 </div>
436 </div>
437 <pre class="example">
438 --, ---
439 </pre>
440 --, ---
441 <pre class="example">
442 --, ---
443 </pre>
444 </li>
445 </ul>
446 </div>
447 </div>
448 <div id="outline-container-headline-22" class="outline-4">
449 <h4 id="headline-22">
450 <span class="todo status-done">DONE</span>
451 <a href="https://github.com/chaseadamsio/goorgeous/issues/87">#87</a>: Markup in footnotes is rendered literally
452 </h4>
453 <div id="outline-text-headline-22" class="outline-text-4">
454 <p>footnotes can contain <strong>markup</strong> - and other elements and stuff <sup class="footnote-reference"><a id="footnote-reference-1" href="#footnote-1">1</a></sup> <sup class="footnote-reference"><a id="footnote-reference-2" href="#footnote-2">2</a></sup></p>
455 </div>
456 </div>
457 <div id="outline-container-headline-23" class="outline-4">
458 <h4 id="headline-23">
459 <span class="todo status-done">DONE</span>
460 <a href="https://github.com/chaseadamsio/goorgeous/issues/92">#92</a>: src blocks only render in caps
461 </h4>
462 <div id="outline-text-headline-23" class="outline-text-4">
463 <p>The behaviour of Org mode <code class="verbatim">&lt;s TAB</code> changed and it now inserts lowercased src blocks (go-org already handled this one)</p>
464 <ul>
465 <li>
466 <p>lowercased:</p>
467 <div class="src src-bash">
468 <div class="highlight">
469 <pre>
470 uname -a
471 </pre>
472 </div>
473 </div>
474 </li>
475 <li>
476 <p>uppercased</p>
477 <div class="src src-bash">
478 <div class="highlight">
479 <pre>
480 uname -a
481 </pre>
482 </div>
483 </div>
484 </li>
485 </ul>
486 </div>
487 </div>
488 </div>
489 </div>
490 <div id="outline-container-headline-24" class="outline-3">
491 <h3 id="headline-24">
492 issues (wrongly) filed with hugo
493 </h3>
494 <div id="outline-text-headline-24" class="outline-text-3">
495 <div id="outline-container-headline-25" class="outline-4">
496 <h4 id="headline-25">
497 <a href="https://github.com/gohugoio/hugo/issues/3874">#3874</a> exporting images in org mode
498 </h4>
499 <div id="outline-text-headline-25" class="outline-text-4">
500 <p>Hello, I&#39;m writing hugo blogs using org-mode.</p>
501 <p>
502 When inserting an image link like <img src="/home/amos/Pictures/Screenshots/img-2017-09-11-165647.png" alt="/home/amos/Pictures/Screenshots/img-2017-09-11-165647.png" title="/home/amos/Pictures/Screenshots/img-2017-09-11-165647.png" />, hugo doesn&#39;t export the image.</p>
503 </div>
504 </div>
505 <div id="outline-container-headline-26" class="outline-4">
506 <h4 id="headline-26">
507 <a href="https://github.com/gohugoio/hugo/issues/4006">#4006</a> source code blocks in org not rendered correctly
508 </h4>
509 <div id="outline-text-headline-26" class="outline-text-4">
510 <div class="src src-emacs-lisp">
511 <div class="highlight">
512 <pre>
513 (defun small-shell ()
514 (interactive)
515 (split-window-vertically)
516 (other-window 1)
517 (shrink-window (- (window-height) 12))
518 (ansi-term))
519 </pre>
520 </div>
521 </div>
522 </div>
523 </div>
524 </div>
525 </div>
526 <div id="outline-container-headline-27" class="outline-3">
527 <h3 id="headline-27">
528 misc fuzz / regression / edge case
529 </h3>
530 <div id="outline-text-headline-27" class="outline-text-3">
531 <div id="outline-container-headline-28" class="outline-4">
532 <h4 id="headline-28">
533 index out of range in headline priority parsing
534 </h4>
535 <div id="outline-text-headline-28" class="outline-text-4">
536 <div id="outline-container-headline-29" class="outline-5">
537 <h5 id="headline-29">
538 [#B
539 </h5>
540 </div>
541 </div>
542 </div>
543 <div id="outline-container-headline-30" class="outline-4">
544 <h4 id="headline-30">
545 index out of range in explicit line break parsing
546 </h4>
547 <div id="outline-text-headline-30" class="outline-text-4">
548 <p>0\\ </p>
549 </div>
550 </div>
551 <div id="outline-container-headline-31" class="outline-4">
552 <h4 id="headline-31">
553 list items don&#39;t end on child headline
554 </h4>
555 <div id="outline-text-headline-31" class="outline-text-4">
556 <ul>
557 <li>a list item</li>
558 </ul>
559 <div id="outline-container-headline-32" class="outline-5">
560 <h5 id="headline-32">
561 followed by a child headline
562 </h5>
563 <div id="outline-text-headline-32" class="outline-text-5">
564 <ul>
565 <li>followed by another list item</li>
566 </ul>
567 </div>
568 </div>
569 </div>
570 </div>
571 </div>
572 </div>
573 <div id="outline-container-headline-33" class="outline-2">
574 <h2 id="headline-33">
575 Footnotes
576 </h2>
577 </div>
578 <div class="footnotes">
579 <hr class="footnotes-separatator"/>
580 <div class="footnote-definitions">
581 <div class="footnote-definition">
582 <sup id="footnote-1"><a href="#footnote-reference-1">1</a></sup>
583 <div class="footnote-body">
584 <p>a footnote <em>with</em> <strong>markup</strong></p>
585 <ul>
586 <li>and a <strong>list</strong></li>
587 <li>because that&#39;s possible</li>
588 </ul>
589 </div>
590 </div>
591 <div class="footnote-definition">
592 <sup id="footnote-2"><a href="#footnote-reference-2">2</a></sup>
593 <div class="footnote-body">
594 <p>that also goes for <strong>inline</strong> footnote <em>definitions</em></p>
595 </div>
596 </div>
597 </div>
598 </div>