| Safe Haskell | None |
|---|---|
| Language | GHC2024 |
MathiasSM.Validate
Description
Build-time checks that content is consistent across files
Synopsis
- ensureContentExists :: IO ()
- validateHobbyPages :: Rules ()
- missingHobbyPages :: [Row] -> [FilePath] -> [FilePath]
- validateNavEntries :: Rules ()
Documentation
ensureContentExists :: IO () #
Stops before building if the content repo is missing, or lacks a file the site needs
Hakyll would otherwise build whatever it finds, silently leaving out missing pages.
validateHobbyPages :: Rules () #
Fails the build, once, if any hobby (shown or not) lacks a published blog post with `path: href`
Runs when the rules are set up, not for every page that lists the hobbies.
missingHobbyPages :: [Row] -> [FilePath] -> [FilePath] #
The href of every hobby that no post path matches
validateNavEntries :: Rules () #
Fails the build, once, listing every page whose menu entry (`nav:`) is invalid
Without this each page would report the same problem while rendering the menu.