Skip to content

Commit 13a1bd8

Browse files
committed
add link to functions. fix functions.txt output alignment.
1 parent 808508f commit 13a1bd8

File tree

2 files changed

+10
-8
lines changed

2 files changed

+10
-8
lines changed

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,8 @@ It defaults to `env` which is effectively the same as the above `--environment=e
7575

7676
## Template Functions
7777

78+
For the full list, see [functions.txt.tmpl](examples/functions/functions.txt.tmpl)
79+
7880
- `add` - `func(a, b int) int`
7981
- `cleanse` - `func(s string) string` - remove `[^[:alpha:]]`
8082
- `commandLine` - `func() string` the command line

examples/functions/functions.txt.tmpl

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5,19 +5,19 @@ line {{next}} debug_toggle = {{debug_toggle}}
55
line {{next}} debugging = {{if debugging}}debugging{{end}}
66
line {{next}} debug = {{debug "message"}}
77
line {{next}} command_line = {{command_line}}
8-
line {{next}} PWD = {{environment "PWD"}}
8+
line {{next}} PWD = {{environment "PWD"}}
99
line {{next}} ip_math = {{ip_math "[-1].[+2].[-3].[+1,%10]" "193.166.3.39"}}
10-
line {{next}} ip4_inc = {{ip4_inc 2 -3 "192.168.3.0"}}
10+
line {{next}} ip4_inc = {{ip4_inc 2 -3 "192.168.3.0"}}
1111
line {{next}} ip4_next = {{ip4_next 2 0 4 "192.168.3.0"}}
1212
line {{next}} ip4_prev = {{ip4_prev 2 1 4 "192.168.1.0"}}
1313
line {{next}} ip_ints = {{ip_ints "192.168.1.0" | ip4_add 2 0 4 3}}
1414
line {{next}} ip_ints = {{ip_ints "192.168.1.0" | ip4_add 2 0 4 3 | ip4_join}}
15-
line {{next}} TODO {{ip6_inc 2 1 "1111:2222:3333:4444:5555:6666:7777:8888"}}
16-
line {{next}} TODO {{ip6_next 2 0 4 "1111:2222:3333:4444:5555:6666:7777:8888"}}
17-
line {{next}} TODO {{ip6_prev 2 0 4 "1111:2222:3333:4444:5555:6666:7777:8888"}}
18-
line {{next}} TODO {{ip_ints "1111:2222:3333:4444:5555:6666:7777:8888" | ip6_add 2 0 4 3}}
19-
line {{next}} TODO {{ip_ints "1111:2222:3333:4444:5555:6666:7777:8888" | ip6_join }}
20-
line {{next}} TODO { {cidr_next} }
15+
line {{next}} TODO = {{ip6_inc 2 1 "1111:2222:3333:4444:5555:6666:7777:8888"}}
16+
line {{next}} TODO = {{ip6_next 2 0 4 "1111:2222:3333:4444:5555:6666:7777:8888"}}
17+
line {{next}} TODO = {{ip6_prev 2 0 4 "1111:2222:3333:4444:5555:6666:7777:8888"}}
18+
line {{next}} TODO = {{ip_ints "1111:2222:3333:4444:5555:6666:7777:8888" | ip6_add 2 0 4 3}}
19+
line {{next}} TODO = {{ip_ints "1111:2222:3333:4444:5555:6666:7777:8888" | ip6_join }}
20+
line {{next}} TODO = { {cidr_next} }
2121
line {{next}} ip_ints = {{ip_ints "192.168.0.0"}}
2222
line {{next}} ip_split = {{ip_split "1111:2222:3333:4444:5555:6666:7777:8888"}}
2323
line {{next}} ip_split = {{ip_split "1111:2222:3333:4444:5555:6666:7777:8888" | to_int 16 }}

0 commit comments

Comments
 (0)