mirror of
https://github.com/RGBCube/nu_scripts
synced 2025-07-30 21:57:44 +00:00
Fixed rusty-paths.nu
entering into rust folder (#1115)
When starting a new shell session inside a rust folder you'd get this error:  This pr fixes this issue. Entering a folder without having a previous folder happen when you for example start a new terminal or starts a multiplexer already inside that folder.
This commit is contained in:
parent
54f10ee7ee
commit
4ecbb0e04e
1 changed files with 1 additions and 1 deletions
|
@ -23,7 +23,7 @@ $env.config = ($env.config | upsert hooks.env_change.PWD {
|
|||
}
|
||||
}
|
||||
| append {
|
||||
condition: {|before, _| ($before | default '' | path join 'Cargo.lock' | path exists) }
|
||||
condition: {|before, _| ($before | default '' | path join 'Cargo.lock' | path exists) and ($before | is-not-empty)}
|
||||
code: {|before, _|
|
||||
$env.PATH = (
|
||||
$env.PATH
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue