tangled
alpha
login
or
join now
matrixfurry.com
/
modcli
0
fork
atom
Easily turn Nushell modules into cross-shell CLI tools
library
nu
nushell
0
fork
atom
overview
issues
pulls
pipelines
template: fix function validation
matrixfurry.com
2 weeks ago
4e03edd2
85edb760
verified
This commit was signed with the committer's
known signature
.
matrixfurry.com
SSH Key Fingerprint:
SHA256:OIsNRui6AFD5q4jnVzMss74Th6LbifKVEEyE9czRgMw=
+2
-1
1 changed file
expand all
collapse all
unified
split
template.nu
+2
-1
template.nu
reviewed
···
25
25
print-functions
26
26
} else {
27
27
let cmd_str = $cmd | str join ' '
28
28
-
let function = get-functions | where $it starts-with $cmd_str | first
28
28
+
let function = get-functions | where ($cmd_str starts-with $it) | first
29
29
30
30
if ($function | is-empty) {
31
31
log error $"Unknown command: `($cmd_str)`"
32
32
print-functions
33
33
+
exit 1
33
34
}
34
35
35
36
exec nu -c $"use ($module_path); ($module_name) ($cmd_str)"