[ANN] soupault: a static website generator based on HTML rewriting

Made a 1.7.0 release.

First improvement is that you now can pipe the content of any element through any external program with preprocess_element widget (PR by Martin Karlsson).
For example, insert inline SVG versions of all graphviz graphs from <pre class="language-graphviz"> and also highlight the Dot source itself with highlight (or any other tool of your choice):

[widgets.graphviz-svg]
  widget = 'preprocess_element'
  selector = 'pre.language-graphviz'
  command = 'dot -Tsvg'
  action = 'insert_after'

[widgets.highlight]
  after = "graphviz-svg"
  widget = "preprocess_element"
  selector = '*[class^="language-"]'
  command = 'highlight -O html -f --syntax=$(echo $ATTR_CLASS | sed -e "s/language-//")'
  action = "replace_content" # default

graphviz_sample

Two other improvements are multiple index “views” and default value option for custom index fields, like

[index.custom_fields]
  category = { selector = "span#category", default = "Misc" }
1 Like