File: os.md

package info (click to toggle)
golang-github-masterminds-sprig 3.2.3-5
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 448 kB
  • sloc: makefile: 10
file content (24 lines) | stat: -rw-r--r-- 457 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# OS Functions

_WARNING:_ These functions can lead to information leakage if not used
appropriately.

_WARNING:_ Some notable implementations of Sprig (such as
[Kubernetes Helm](http://helm.sh) _do not provide these functions for security
reasons_.

## env

The `env` function reads an environment variable:

```
env "HOME"
```

## expandenv

To substitute environment variables in a string, use `expandenv`:

```
expandenv "Your path is set to $PATH"
```