mirror of
https://github.com/JanDeDobbeleer/oh-my-posh.git
synced 2024-12-28 04:19:41 -08:00
docs(nushell): revise descriptions about init
This commit is contained in:
parent
4f594f19b1
commit
0575e6d78d
|
@ -139,21 +139,32 @@ Once altered, reload your config for the changes to take effect.
|
|||
Oh My Posh requires Nushell >= 0.60.0
|
||||
:::
|
||||
|
||||
Edit `$nu.configuration/path` and add the following lines at the bottom.
|
||||
Run the following command:
|
||||
|
||||
```bash
|
||||
oh-my-posh init nu --config ~/.jandedobbeleer.omp.json
|
||||
```
|
||||
|
||||
it saves the initialization script to `~/.oh-my-posh.nu` by default.
|
||||
Then edit the Nushell config file (`$nu.config-path`) and add the following line at the bottom:
|
||||
|
||||
```bash
|
||||
source ~/.oh-my-posh.nu
|
||||
```
|
||||
|
||||
If you want to save the initialization script elsewhere, replace the lines above with these:
|
||||
If you want to save the initialization script elsewhere, you should run a command like:
|
||||
|
||||
```bash
|
||||
oh-my-posh init nu --config ~/.jandedobbeleer.omp.json --print | save /mylocation/myscript.nu
|
||||
```
|
||||
|
||||
and add the `source` line like:
|
||||
|
||||
```bash
|
||||
source /mylocation/myscript.nu
|
||||
```
|
||||
|
||||
Once altered, restart nu shell for the changes to take effect.
|
||||
Once altered, restart Nushell for the changes to take effect.
|
||||
|
||||
</TabItem>
|
||||
</Tabs>
|
||||
|
|
|
@ -160,21 +160,32 @@ exec fish
|
|||
Oh My Posh requires Nushell >= 0.60.0
|
||||
:::
|
||||
|
||||
Edit `$nu.config-path` and add the following lines at the bottom.
|
||||
Run the following command:
|
||||
|
||||
```bash
|
||||
oh-my-posh init nu
|
||||
```
|
||||
|
||||
it saves the initialization script to `~/.oh-my-posh.nu` by default.
|
||||
Then edit the Nushell config file (`$nu.config-path`) and add the following line at the bottom:
|
||||
|
||||
```bash
|
||||
source ~/.oh-my-posh.nu
|
||||
```
|
||||
|
||||
If you want to save the initialization script elsewhere, replace the lines above with these:
|
||||
If you want to save the initialization script elsewhere, you should run a command like:
|
||||
|
||||
```bash
|
||||
oh-my-posh init nu --print | save /mylocation/myscript.nu
|
||||
```
|
||||
|
||||
and add the `source` line like:
|
||||
|
||||
```bash
|
||||
source /mylocation/myscript.nu
|
||||
```
|
||||
|
||||
Restart Nushell for the changes to take effect.
|
||||
Once added, restart Nushell for the changes to take effect.
|
||||
|
||||
</TabItem>
|
||||
</Tabs>
|
||||
|
|
Loading…
Reference in a new issue