Loosen dependency constraints
Fix: Ignore emacs *Messages* + Fix: :body_with_resources option.
Initial commit. Working Tilt::EmacsOrg
A native Org Mode parser for Tilt.
emacs
tilt-emacs_org
gemrequire 'tilt/emacs_org'
template = Tilt.new('file.org', 1, { setupfile: 'setup.org' })
template.title # document title
template.head # scripts, links and styles on head
template.render # body of HTML document
This is an example usage, render can vary depending on options. All options are optional.
:format => :body_only|:body_with_resources|:full
Defaults to :body_only
.
:body_only
renders body only, discarding head section of the document.:body_with_resources
renders body with head script, link and style elements
on top of the rest of the body.:full
renders a full HTML document, just as emacs exports it.You can always access head script, link and style elements by calling
EmacsOrgTemplate#head
, and document title by calling EmacsOrgTemplate#title
.
:setupfile
If set, include a #+SETUPFILE
on top of the document. Useful for default
options.
Source code is available on https://git.hacktivista.org/tilt-emacs_org.
Bug reports and patches are welcome on https://lists.hacktivista.org/hacktivista-dev.
The gem is available as libre software under the terms of the MIT License.