This quickly generates an HTML preview of the ACT Rules markdown files on your current branch, so can be used to check your own PRs before committing and to review other peoples PRs.
- no dependencies other than Hugo (and Hugo itself has no dependencies) so easy to get working
- very quick to generate a preview (less than 0.2 seconds to process all markdown files)
- Download the
act-rules-previewrepo as a sibling folder ofact-rulesrepo - Download and install hugo from https://gohugo.io/installation/
cdto theact-rules-previewfolder which containsconfig.toml(see below)- Run the
hugocommand with no parameters
The contentdir property in config.toml specifies where to find the markdown files.
The published rules files are in the public folder.
config.tomlis the main hugo configuration filelayouts/_default/home.htmlis the template that generates the home pagelayouts/_default/list.htmlis currently unusedlayouts/_default/single.htmlis the template that generates rules pageslayouts/partials/single.htmlis the template that generates rules pagesstatic/css/preview.cssis the CSS file for the generated pagespubliccontains the generated html files
- local definitions like
[attribute value ][]are not included in built HTML