rocher / mold

Meta-variable Operations for Lean Development
https://rocher.github.io/mold
MIT License
4 stars 0 forks source link
ada alire-crate template template-engine template-project

Alire Alire CI/CD GitHub release License

Welcome to Mold

MOLD: Meta-variable Operations for Lean Development

Mold is a Template Processor, or Template Engine, to work with repository templates. The main motivation of Mold is to have repositories in GitHub used as template repositories to create new, customized repositories for other users.

Mold is the CLI wrapper of the mold_lib, the Ada library that implements all Mold functionality.

Main features supported in Mold include

Variable replacement can be specified as normal, optional or mandatory. For example, the variable foo = "bar" can be specified with {{foo}}, {{?foo}} (optional) or {{#foo}} (mandatory). The difference is the handling of errors when an undefined variable is encountered.

All mold files must end with the extension .mold, for example README.md.mold. Destination files (with variables replaced) have the same name without the mold extension: README.md. This simplifies the work done in large subdirectories with few templates.

This crate contains the Ada library and unit tests. For a CLI tool, please take a look at the crate mold.

Reference Guide

Please visit Mold documentation for more information.


License

MIT (c) 2023, 2024 Francesc Rocher