Makeweb is a very simple static-site generator. Its only dependencies are
multimarkdown[1], scp (to upload to the target server) and a POSIX system to
run on.
It generates bare-bones web pages based on markdown input, adding two special
files:
- contents.html -- a list of all pages (see TOC variable below);
- keywords.html -- a keyword index (see INDEX variable below).
USAGE
To build a site, put your markdown files in a subdirectory ('_posts' by
default) and run make(1):
$ make web
You can use the following variables to overwrite makeweb defaults:
- TOC - name of the Table of Contents file;
- INDEX - name of the Keyword Index file;
- POSTS - where to find the markdown files;
- BUILD_DIR - where the HTML output should be saved;
- MMD - path of the multimarkdown program, if not found in $PATH.
- CUSTOM_CONFIG - path of an additional Makefile to include.
To customise presentation of the pages generated by multimarkdown, use the
`css:' property in the front matter to provide location of the CSS sheet.
CUSTOMISATION
To include some files not processed by makeweb in ${BUILD_DIR} (for easier
distribution), you can add custom definitions. For example, to include a CSS
file you can save following definitions in custom.mk:
web: copy-css
copy-css:
cp s.css ${BUILD_DIR}/
and then just run:
$ make CUSTOM_CONFIG=custom.mk
Make will figure out additional dependencies and include the CSS in the output
directory. This method can also be used to change variables like TOC, INDEX,
POSTS and so on.
References:
[1] https://fletcherpenney.net/multimarkdown/