patched https://github.com/niklasfasching/go-org for orgwiki
We want original whitespace to be rendered in some cases (e.g. verse blocks). This requires information about the original whitespace to be preserved during paragraph parsing. As html ignores (collapses) whitespace by default we don't have to adapt the html writer and can just selectively enable rendering of the preseverved whitespace wherever we want it using css (white-space: pre). To differentiate meaningful whitespace from document structure based indentation (i.e. list item base indentation) we need to introduce document.baseLvl. A paragraph by itself does not have enough information to differentiate both kinds of whitespace and needs this information as context [0]. As we're already touching list indentation i went along and improved (fixed?) descriptive list item indentation rendering in the org writer (it should match emacs tab behavior - i.e. indent subsequent lines up to the `:: `). [0] e.g. list items can contain blank lines - a paragraph starting with a blank line would not know that it is part of a list item / has a base indentation - the blank line would suggest a baseLvl of 0. |
||
---|---|---|
etc | ||
org | ||
.gitignore | ||
.travis.yml | ||
LICENSE | ||
main.go | ||
Makefile | ||
README.org |
- go-org https://travis-ci.org/niklasfasching/go-org.svg?branch=master
- development
- not yet implemented
- resources
go-org https://travis-ci.org/niklasfasching/go-org.svg?branch=master
An Org mode parser in go.
Take a look at github pages for some examples and an online org -> html demo (wasm based).
Please note that the goal for the html export is to produce sensible html output, not to exactly reproduce output the output of
org-html-export
.
development
make setup install
- change things
make preview
(regenerates fixtures & shows output in a browser)
in general, have a look at the Makefile - it's short enough.
not yet implemented
deadlines and scheduling
more types of links
see https://orgmode.org/manual/External-links.html & https://orgmode.org/manual/Internal-links.html
- radio target <<<MyTarget>>>
- link target: <<go-org>>
- link: /OrgWiki/go-org-orgwiki/src/commit/b61e49eb855db4f488fa464e06f3f064478866dc/go-org
- link to headline
- links with image as description
- MyTarget <- this will automatically become a link - not sure i want this…
resources
-
test files
- https://orgmode.org/manual/
- https://orgmode.org/worg/dev/org-syntax.html
-
https://code.orgmode.org/bzg/org-mode/src/master/lisp/org.el
- https://code.orgmode.org/bzg/org-mode/src/master/lisp/org-element.el
- mostly those & ox-html.el, but yeah, all of https://code.orgmode.org/bzg/org-mode/src/master/lisp/
- existing Org mode implementations: org, org-ruby, goorgeous, pandoc