.Kind (home): .Type (page) / .Layout ()
Bundle: branch
[ categories | tags | search ]
ox-hugo Test Site

This is the test site for the ox-hugo package for Emacs/Org-mode.

It is updated automatically after each commit to the ox-hugo repo. It was last updated on Sep 18, 2018 04:15 UTC.


This page was created/modified in commit f0dd0e2 "Support image copying for the homepage branch bundle case" on 2018-04-23.
Markdown source of this page

Content

Image in homepage branch bundle:


Resources

Suppress lastmod non-zero, but date unset

(Last modified on Sat Sep 15, 2018)

Ensure that nil value of parsed DATE is also handled in the “suppress lastmod” logic.

Table caption

(Last modified on Fri Sep 7, 2018)

The caption can contain be emphasized using the usual markup characters too. Table 1: Awesome table h1 h2 h3 abc def ghi Some text. Table 2: Another awesome table h1 h2 h3 jkl mno pqr Some more text. Table 3: Third table — Caption with em-dash – and – en-dash h1 h2 h3 stu vwx yz

Table Styling with ATTR_HTML and ATTR_CSS

(Last modified on Fri Sep 7, 2018)

This table styling feature overcomes a known limitation in Hugo/Blackfriday (Blackfriday Issue #404) that doesn’t allow wrapping Markdown elements with <div> tags (so that a user can assign classes, etc. to those div blocks). So this feature had to be implemented at the expense of a nasty hack demonstrated here. HTML5 does not allow align, width, etc. attributes within the table tag [Ref]. So instead ox-hugo simply wraps the table with a div with a class.

Links to tables

(Last modified on Fri Sep 7, 2018)

Note: When targeting a #+name keyword, #+caption keyword is mandatory in order to get proper numbering for source blocks, images and tables. #+caption: Simple table 1 #+name: tab__simple1 | a | b | | c | d | *Here we refer to table [[tab__simple2]].* #+include: "./all-posts.org::#lorem-ipsum" :only-contents t Here's another table: #+caption: Simple table 2 #+name: tab__simple2 | e | f | | g | h | *Here we refer to table [[tab__simple1]].

Source block with caption

(Last modified on Fri Sep 7, 2018)

prefix = /dir/where/you/want/to/install/org # Default: /usr/share Code Snippet 1: Prefix value in local.mk (message "hello") Code Snippet 2: Hello — Caption with em-dash – and – en-dash

Links to source blocks

(Last modified on Fri Sep 7, 2018)

From (org) Internal links, If no dedicated target exists, the link will then try to match the exact name of an element within the buffer. Naming is done with the ‘#+name’ keyword, which has to be put in the line before the element it refers to, as in the following example #+name: My Target | a | table | |----+------------| | of | four cells | Also, when targeting a #+name keyword, #+caption keyword is mandatory in order to get proper numbering for source blocks, images and tables.

Citations with captions

(Last modified on Fri Sep 7, 2018)

This test tests the following:

  • Pandoc leave the HTML span tags as-is.
  • Pandoc does not escape the < in the figure shortcodes with captions (in general: {{< ..>}} shortcodes that could wrap across lines).
  • While Pandoc auto-wraps the re-written Markdown, it also wraps the {{< .. >}} shortcodes. The test checks that such “wrapped shortcodes” get unwrapped.

Default Creator

(Last modified on Wed Sep 5, 2018)

The front-matter for this post contains the default Creator string.

Auto-set Lastmod

(Last modified on Wed Sep 5, 2018)

This post will have its lastmod field in the front-matter auto-updated the time it gets exported each time.

Writing Hugo blog in Org (File Export)

(Last modified on Wed Sep 5, 2018)

First heading within the post This post will be exported as content/posts/writing-hugo-blog-in-org-file-export.md. Its title will be “Writing Hugo blog in Org”. It will have hugo and org tags and emacs as category. The lastmod property in the front-matter is set automatically to the time of export. The menu item identifier is auto-set. The menu item weight and post weight if needed have to be manually specified as shown above.


SiteInfo (Debug)

SiteInfo VariableValue
Title "ox-hugo Test Site"
Author
KeyTypeValue
namestring "Kaushal Modi"
Social
KeyTypeValue
githubstring "kaushalmodi"
LastChange 2018-09-15 02:46:34 -0400 -0400
DisqusShortname ""
GoogleAnalytics ""
Copyright ""
RSSLink "https://ox-hugo.scripter.co/test/index.xml"
LanguageCode "en-us"
BuildDrafts true
Params
KeyTypeValue
custom_css[]interface {} "css/style.css"
descriptionstring "Test site for ox-hugo package for Emacs/Org-mode."
footerstring "<div style=\"text-align: center;\">\n [<a href=\"/\">Test Site home</a> | <a href=\"https://ox-hugo.scripter.co/\"><code>ox-hugo</code> home</a>]\n</div>\n"
introstring "This is the test site for the <a href=\"https://github.com/kaushalmodi/ox-hugo\">\n<code>ox-hugo</code></a> package for Emacs/Org-mode.\n"
mainSections[]string "posts"
mainsections[]string "posts"
sourcemap[string]interface {}
KeyTypeValue
md_dirstring "test/site/content"
org_dirstring "test/site/content-org"
urlstring "https://github.com/kaushalmodi/ox-hugo"

File Object (Debug)

FileInfo VariableValue
UniqueID "3976528693a0108357f4928017600865"
BaseFileName "_index"
TranslationBaseName "_index"
Lang "en"
Section ""
LogicalName "_index.md"
Dir ""
Ext "md"
Path "_index.md"

Menu (Debug)

KeyTypeValue
0.search*hugolib.Menu
MenuEntry VariableValue
Menu "0.search"
Title "Click to Search"
Name "Search"
URL "/search/"
Identifier "search"
Weight 2001
Pre ""
Post ""
Parent ""
Children
auto weight*hugolib.Menu
MenuEntry VariableValue
Menu "auto weight"
Title "Post with menu 1 (HUGO_MENU as keyword)"
Name "Post with menu 1 (HUGO_MENU as keyword)"
URL "/posts/hugo-menu-as-keyword--post-with-menu-1/"
Identifier "post-with-menu-1--hugo-menu-as-keyword"
Weight 1001
Pre ""
Post ""
Parent ""
Children
MenuEntry VariableValue
Menu "auto weight"
Title "Post with menu 2 (HUGO_MENU as keyword)"
Name "Post with menu 2 (HUGO_MENU as keyword)"
URL "/posts/hugo-menu-as-keyword--post-with-menu-2/"
Identifier "post-with-menu-2--hugo-menu-as-keyword"
Weight 1002
Pre ""
Post ""
Parent ""
Children
MenuEntry VariableValue
Menu "auto weight"
Title "Post with menu 3 (HUGO_MENU as keyword)"
Name "Post with menu 3 (HUGO_MENU as keyword)"
URL "/posts/hugo-menu-as-keyword--post-with-menu-3/"
Identifier "post-with-menu-3--hugo-menu-as-keyword"
Weight 1003
Pre ""
Post ""
Parent ""
Children
MenuEntry VariableValue
Menu "auto weight"
Title "Post with menu 4 (HUGO_MENU as keyword)"
Name "Post with menu 4 (HUGO_MENU as keyword)"
URL "/posts/hugo-menu-as-keyword--post-with-menu-4/"
Identifier "post-with-menu-4--hugo-menu-as-keyword"
Weight 1004
Pre ""
Post ""
Parent ""
Children
MenuEntry VariableValue
Menu "auto weight"
Title "Post with menu 5 (HUGO_MENU as keyword)"
Name "Post with menu 5 (HUGO_MENU as keyword)"
URL "/posts/hugo-menu-as-keyword--post-with-menu-5/"
Identifier "post-with-menu-5--hugo-menu-as-keyword"
Weight 1005
Pre ""
Post ""
Parent ""
Children
MenuEntry VariableValue
Menu "auto weight"
Title "Post with menu 1"
Name "Post with menu 1"
URL "/posts/post-with-menu-1/"
Identifier "post-with-menu-1"
Weight 4001
Pre ""
Post ""
Parent ""
Children
MenuEntry VariableValue
Menu "auto weight"
Title "Post with menu 2"
Name "Post with menu 2"
URL "/posts/post-with-menu-2/"
Identifier "post-with-menu-2"
Weight 4002
Pre ""
Post ""
Parent ""
Children
MenuEntry VariableValue
Menu "auto weight"
Title "Post with menu 3"
Name "Post with menu 3"
URL "/posts/post-with-menu-3/"
Identifier "post-with-menu-3"
Weight 4003
Pre ""
Post ""
Parent ""
Children
MenuEntry VariableValue
Menu "auto weight"
Title "Post with menu 4"
Name "Post with menu 4"
URL "/posts/post-with-menu-4/"
Identifier "post-with-menu-4"
Weight 4004
Pre ""
Post ""
Parent ""
Children
MenuEntry VariableValue
Menu "auto weight"
Title "Post with menu 5"
Name "Post with menu 5"
URL "/posts/post-with-menu-5/"
Identifier "post-with-menu-5"
Weight 4005
Pre ""
Post ""
Parent ""
Children
foo*hugolib.Menu
MenuEntry VariableValue
Menu "foo"
Title "Keyword Collection"
Name "Keyword Collection"
URL "/posts/keyword-collection/"
Identifier "keyword-collection"
Weight 10
Pre ""
Post ""
Parent ""
Children
MenuEntry VariableValue
Menu ""
Title ""
Name "main"
URL ""
Identifier ""
Weight 0
Pre ""
Post ""
Parent ""
Children
MenuEntry VariableValue
Menu "foo"
Title "Single Post with TOML front matter"
Name "Single Post with TOML front matter"
URL "/singles/post-toml/"
Identifier "single-toml"
Weight 10
Pre ""
Post ""
Parent "main"
Children
MenuEntry VariableValue
Menu "foo"
Title "Single Post with YAML front matter"
Name "Single Post with YAML front matter"
URL "/singles/post-yaml/"
Identifier "single-yaml"
Weight 10
Pre ""
Post ""
Parent "main"
Children
MenuEntry VariableValue
Menu "foo"
Title "Single Post, but draft"
Name "Single Post, but draft"
URL "/singles/post-draft/"
Identifier "single-post-but-draft"
Weight 10
Pre ""
Post ""
Parent "main"
Children
main*hugolib.Menu
MenuEntry VariableValue
Menu "main"
Title "Writing Hugo blog in Org"
Name "Writing Hugo blog in Org"
URL "/writing-hugo-blog-in-org-subtree-export/"
Identifier "writing-hugo-blog-in-org"
Weight 2001
Pre ""
Post ""
Parent ""
Children
MenuEntry VariableValue
Menu "main"
Title "Writing Hugo blog in Org (File Export)"
Name "Writing Hugo blog in Org (File Export)"
URL "/writing-hugo-blog-in-org-file-export/"
Identifier "writing-hugo-blog-in-org--file-export"
Weight 2001
Pre ""
Post ""
Parent ""
Children
MenuEntry VariableValue
Menu ""
Title ""
Name "posts"
URL ""
Identifier ""
Weight 0
Pre ""
Post ""
Parent ""
Children
MenuEntry VariableValue
Menu "main"
Title "Menu Meta Data in YAML Front Matter"
Name "Menu Meta Data in YAML Front Matter"
URL "/posts/menu-meta-data-yaml/"
Identifier "yaml-menu-override"
Weight 25
Pre ""
Post ""
Parent "posts"
Children
MenuEntry VariableValue
Menu "main"
Title "White space in menu name"
Name "Menu in YAML"
URL "/posts/menu-meta-data-yaml3/"
Identifier "white-space-in-menu-name"
Weight 25
Pre ""
Post ""
Parent "posts"
Children
something here*hugolib.Menu
MenuEntry VariableValue
Menu "something here"
Title "White space in menu entry"
Name "White space in menu entry"
URL "/posts/menu-meta-data-yaml2/"
Identifier "white-space-in-menu-entry"
Weight 25
Pre ""
Post ""
Parent ""
Children
MenuEntry VariableValue
Menu ""
Title ""
Name "posts"
URL ""
Identifier ""
Weight 0
Pre ""
Post ""
Parent ""
Children
MenuEntry VariableValue
Menu "something here"
Title "Overriding few menu properties"
Name "Overriding few menu properties"
URL "/posts/menu-alist-meta-data-toml-override-partial/"
Identifier "ov-partial"
Weight 10
Pre ""
Post ""
Parent "posts"
Children
test*hugolib.Menu
MenuEntry VariableValue
Menu "test"
Title "Overriding menu properties completely"
Name "Overriding menu properties completely"
URL "/posts/menu-alist-meta-data-toml-override-full/"
Identifier "overriding-menu-properties-completely"
Weight 50
Pre ""
Post ""
Parent ""
Children
MenuEntry VariableValue
Menu "test"
Title "Page title for menu"
Name "Menu Title property"
URL "/posts/menu-title-property/"
Identifier "menu-title-property"
Weight 3003
Pre ""
Post ""
Parent ""
Children

This site is generated using the ox-hugo package for Emacs/Org-mode + hugo-bare-min-theme + Hugo 0.49-DEV (commit 5f6653f3, using Chroma commit d5ca12b) .
[Test Site home | ox-hugo home]