/tera-cli

Simple cli tool to render tera templates

Primary LanguageRust

tera-cli

Simple cli tool to render tera templates.

tera is a Jinja2 like template engine written in Rust.

Usage

tera-cli: Simple cli tool to render tera templates

Usage: tera [OPTIONS] <TEMPLATE_DIR> <OUTPUT_DIR>

Arguments:
  <TEMPLATE_DIR>  The path to the template file to read
  <OUTPUT_DIR>    The path to the output file

Options:
  -w, --watch    Watch for changes in template_dir
  -h, --help     Print help
  -V, --version  Print version

Install from Github Release

You can download the binary from the github release page.

Look for the url of the binary for your platform, e.g. https://github.com/kj-9/tera-cli/releases/download/v0.0.1/tera-aarch64-apple-darwin.tar.gz.

download and install the binary:

curl -O -L https://github.com/kj-9/tera-cli/releases/download/v0.0.1/tera-aarch64-apple-darwin.tar.gz
tar -xzf tera-aarch64-apple-darwin.tar.gz
mv tera /usr/local/bin/
tera --version

Develop

Setup

you need cargo:

curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh

you need just to run dev tools:

brew install just

you need some python tools, pre-commmit and commitize. I recommend using pipx:

brew install pipx
pipx install pre-commit commitizen
pre-commit install

Lint

just lint

Commit

cz c

Release

bump version for pre-release:

just pre-release-dry-run # check what will be changed
just pre-release

bump version for release:

just release-dry-run # check what will be changed
just release