Mksite

screenshot of Mksite

A file format-agnostic static site generator

Overview

mksite is a versatile static site generator that operates independently of file formats, making it an excellent choice for developers and content creators looking to transform a directory of text files into a fully functional website. Built using Rust and Cargo, mksite provides a robust framework for creating websites in various languages, including LaTex, HTML, and Markdown, among others. Its flexible configuration allows for easy customization, ensuring users can tailor their projects to suit unique needs.

The directory structure of mksite projects is straightforward, enabling users to define layouts, sources, static files, and outputs with ease. By leveraging Tera's templating language and defining custom transforms, mksite empowers its users to create dynamic and richly formatted websites with minimal hassle.

Features

  • File Format Agnostic: Supports a variety of source file types, allowing users to work with Markdown, HTML, LaTex, or custom markup languages.

  • Customizable Directory Structure: Users can easily configure the names of source, output, static, and layout directories in the mksite.toml file, providing maximum flexibility.

  • Tera Templating Integration: Leverages the Tera templating language, enabling sophisticated templating capabilities right out of the box.

  • Transform Command Support: Allows users to define transforms that manipulate file content, facilitating features like syntax highlighting and markdown rendering through custom commands.

  • Static File Handling: The static/ directory accommodates non-templated files such as images and CSS, ensuring they are copied directly to the output without alteration.

  • Optional Layout Directory: Users can include an optional layout/ directory to define HTML boilerplates or skip layouts altogether.

  • UTF-8 Compatibility: Ensures all source files must be valid UTF-8, enhancing compatibility across various file types.

  • Arbitrary Data Support: Users can define custom data sections in mksite.toml to enrich template rendering, providing greater personalization opportunities.