source
for core> source {flags} (filename)
filename
: the filepath to the script file to sourceinput | output |
---|---|
any | any |
Runs foo.nu in the current context
>sourcefoo.nu
Runs foo.nu in current context and call the command defined, suppose foo.nu has content: def say-hi [] { echo 'Hi!' }
>source./foo.nu;say-hi
This command is a parser keyword. For details, check: https://www.nushell.sh/book/thinking_in_nu.html
Copyright © 2019–2023 The Nushell Project DevelopersLicensed under the MIT License.
https://www.nushell.sh/commands/docs/source.html