The full list of functions and filters registered with the minijinja environment, grouped by category. Run guisu variables to inspect what is available in a given context.
Note
Functions vs filters
A function is called with parentheses: fn(arg). A filter is applied with the pipe operator: value | filter. The same underlying operation may exist as both — see the encryption row below.
Function Returns Notes
os()string "darwin", "linux", or "windows".
arch()string "x86_64", "aarch64", "arm".
hostname()string Machine hostname.
username()string Current OS user.
home_dir()string $HOME.
Function Returns Notes
env("NAME")string Empty string if unset.
lookPath("cmd")string Absolute path of cmd on $PATH, or empty if not found.
Function Returns Notes
joinPath("a", "b", "c")string Join path components portably.
All four functions are available when the [bitwarden] provider is configured. Caching is per-apply.
Function Returns Notes
bitwarden("Item")object The full Bitwarden item as a JSON object.
bitwardenFields("Item", "Field")value A specific custom field on the item.
bitwardenAttachment("Item", "filename")string An attachment’s contents as a string.
bitwardenSecrets("Item", "Field")string A secret field (Bitwarden Secrets only).
Function Returns Notes
include("name")string The raw content of another template file.
includeTemplate("name")string Include and render a template file with the current context.
These are filters (not functions) — they go on the right side of a |.
Filter Returns Notes
value | decryptstring Decrypt an inline age:base64,... string.
value | encryptstring Encrypt a string for the configured recipients.
export TOKEN="{{ 'age:base64,YWdl...' | decrypt }}"
Function Returns Notes
regexMatch(pattern, string)bool True if the regex matches anywhere.
regexReplaceAll(pattern, replacement, string)string Replace all matches.
split(separator, string)list Split a string into a list.
join(separator, list)string Join a list into a string.
Filter Returns Notes
s | quotestring Surround with double quotes; escape inner quotes.
s | trimstring Strip leading and trailing whitespace.
s | trimStartstring Strip leading whitespace.
s | trimEndstring Strip trailing whitespace.
s | customstring Uppercase the string. (Built-in alias; useful for templates.)
Filter Returns Notes
value | toJsonstring Serialise to JSON.
s | fromJsonvalue Parse JSON.
value | toTomlstring Serialise to TOML.
s | fromTomlvalue Parse TOML.
Filter Returns Notes
s | blake3sumstring Hex-encoded BLAKE3-256 of the input.
Tip
Generated inline values
Run guisu age encrypt --inline "my secret" to print an inline-encrypted value. The output can be committed safely and embedded in templates as {{ 'value' | decrypt }}.