Skip to content

Commit

Permalink
add a more complete example to persist aliases in config.nu (#973)
Browse files Browse the repository at this point in the history
  • Loading branch information
amtoine authored Jul 2, 2023
1 parent 56110b3 commit 4072fad
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions book/aliases.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,17 @@ Your useable aliases can be seen in `$nu.scope.aliases`.
## Persisting

To make your aliases persistent they must be added to your _config.nu_ file by running `config nu` to open an editor and inserting them, and then restarting nushell.
e.g. with the above `ll` alias, you can add `alias ll = ls -l` anywhere in _config.nu_

```nushell
$env.config = {
# main configuration
}
alias ll = ls -l
# some other config and script loading
```

## Piping in aliases

Expand Down

0 comments on commit 4072fad

Please sign in to comment.