2023-10-12 14:03:03 -04:00
|
|
|
# spry
|
|
|
|
|
2023-10-27 08:02:38 -04:00
|
|
|
Basic [Sprig](https://masterminds.github.io/sprig/) &
|
|
|
|
[Helm Templating Language (HTL)](https://helm.sh/docs/howto/charts_tips_and_tricks/#know-your-template-functions)
|
|
|
|
Template Rendering Tool.
|
|
|
|
|
|
|
|
It's design emulates how the `helm template` command runs, for rendering simple
|
|
|
|
Go Templates, Sprig extended Go Templates, or Helm Templating Language (HTL)
|
|
|
|
Templates, outside of a Helm Chart.
|
|
|
|
|
|
|
|
It takes provided templates and renders them using provided values.
|
|
|
|
|
|
|
|
### _ Files
|
|
|
|
|
|
|
|
Like with `helm template` template files whose names begins with `_` will not
|
|
|
|
produce output, but are used to provide common code used in other template
|
|
|
|
files.
|
2023-10-13 09:13:18 -04:00
|
|
|
|
|
|
|
## Usage Examples
|
|
|
|
|
|
|
|
```bash
|
|
|
|
$ ./spry
|
2023-10-13 09:51:56 -04:00
|
|
|
Usage of ./spry [Options] [Template Files]:
|
2023-10-13 09:13:18 -04:00
|
|
|
-d string
|
|
|
|
Output delimiter between template files rendered (default "---")
|
2023-10-23 05:48:16 -04:00
|
|
|
-delimErr
|
|
|
|
Whether to print output delimiter to STDERR.
|
2023-10-13 09:13:18 -04:00
|
|
|
-f value
|
|
|
|
Specify a values file (JSON or YAML)
|
2023-10-23 05:48:16 -04:00
|
|
|
-filenameErr
|
|
|
|
Whether to print filename to STDERR. (default true)
|
|
|
|
-fp string
|
|
|
|
Prefix for the filename in the output. (default "# ")
|
2023-10-13 09:26:16 -04:00
|
|
|
-helm
|
2023-10-27 08:02:38 -04:00
|
|
|
Use the Helm Templating Language (HTL) (a superset of Sprig).
|
2023-10-23 05:48:16 -04:00
|
|
|
-helmDNS
|
2023-10-27 08:02:38 -04:00
|
|
|
When using HTL, support DNS resolution. (default true)
|
|
|
|
-helmLin
|
|
|
|
When using HTL, enable the Linting Mode.
|
2023-10-23 05:48:16 -04:00
|
|
|
-helmNestValues
|
2023-10-27 08:02:38 -04:00
|
|
|
When using HTL, Nest provided values under '.Values' (default true)
|
2023-10-23 05:48:16 -04:00
|
|
|
-helmStrict
|
2023-10-27 08:02:38 -04:00
|
|
|
When using HTL, use strict rendering.
|
2023-10-13 09:13:18 -04:00
|
|
|
-set value
|
|
|
|
Set a specific value (foo.bar=spam)
|
2023-10-27 08:02:38 -04:00
|
|
|
-v Print the version and exit.
|
|
|
|
-version
|
|
|
|
Print the version and exit.
|
2023-10-13 09:51:56 -04:00
|
|
|
|
|
|
|
Template Files can also be directories to recurse for templates.
|
|
|
|
|
|
|
|
If no template files are provided it will attempt read from STDIN.
|
|
|
|
If no input is available from STDIN it will print this usage message instead.
|
|
|
|
Pass only '-' to Template Files to force waiting for input.
|
2023-10-23 05:48:16 -04:00
|
|
|
|
|
|
|
Helm Mode: use the Helm Templating Language/Engine
|
|
|
|
with the following caveats:
|
|
|
|
- 'lookup' function unavailable.
|
2023-10-13 09:13:18 -04:00
|
|
|
```
|