From 52f86ea0075c66e18e4796ad88f45541da8b4de5 Mon Sep 17 00:00:00 2001 From: Miguel Date: Thu, 7 Mar 2019 23:26:17 +0100 Subject: some cleanup and such --- .../00200_Estatico-Page-Maker/index.md | 55 ++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 080_blog/00040_Haskell/00200_Estatico-Page-Maker/index.md (limited to '080_blog/00040_Haskell/00200_Estatico-Page-Maker') diff --git a/080_blog/00040_Haskell/00200_Estatico-Page-Maker/index.md b/080_blog/00040_Haskell/00200_Estatico-Page-Maker/index.md new file mode 100644 index 0000000..63f9816 --- /dev/null +++ b/080_blog/00040_Haskell/00200_Estatico-Page-Maker/index.md @@ -0,0 +1,55 @@ +# estático - static website generator + + April 12, 2018 + +Two weeks ago I decided to switch my website from a well known PHP +driven CMS solution, to a light and static set of HTML pages. + +And so I wrote a simple static website generator in +**Haskell**. Of course I know that there are already hundreds out there, +but I wanted my own masturbatory solution. + +I use **pandoc** et al. for most of the work anyway. + +## Features + +* **No** Database +* Input with Simple **Markdown** Files +* Generates **Static HTML** Content +* Embedding data **fetched** via **http/https** +* Embedding self-hosted **asciinema** casts +* Embedding Latex formulas via **MathJx** +* Image Scaling with **ImageMagick** +* Syntax **Highlighting** + +## Try It +You can find the most recent version following the links below. +Build it with _stack_ or use the docker images. + +* +* +* + +## Example Usage +__NOTE: make sure DIR\_OUT exists and is a free directory__ + +You can use the example websites inside the examples/ directory for a start. + +Inside the input directory (e.g. ./examples/example01/) run something along this lines: + + DIR_IN=`pwd` + DIR_OUT=/mnt/yourwebsiteroot + HTML_ROOT=https://www.example.com + SUDO=sudo + IMAGE=migueldirty/estatico + ${SUDO} docker run --rm -v${DIR_IN}:/in:ro -v${DIR_OUT}:/out:rw ${IMAGE} /in /out ${HTML_ROOT} + +Or if you want to test it locally use some local DIR\_OUT and HTML\_ROOT instead: + + DIR_OUT=/home/miguel/testpage + HTML_ROOT=/home/miguel/testpage + +The only real life example I know of, is this very page: _idziorek.net_ +You can find it's sources here: + +* -- cgit v1.2.3