Add direnv to nu config
This commit is contained in:
@@ -282,7 +282,11 @@ let-env config = {
|
||||
|
||||
hooks: {
|
||||
pre_prompt: [{
|
||||
$nothing # replace with source code to run before the prompt is shown
|
||||
code: "
|
||||
let direnv = (direnv export json | from json)
|
||||
let direnv = if ($direnv | length) == 1 { $direnv } else { {} }
|
||||
$direnv | load-env
|
||||
"
|
||||
}]
|
||||
pre_execution: [{
|
||||
$nothing # replace with source code to run before the repl input is run
|
||||
|
||||
Reference in New Issue
Block a user