You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
posh-direnv often silently fails to apply .psenvrc changes. I go through the Edit-DirEnvRc workflow, and even close and relaunch PowerShell. But still, the changes fail to take effect.
As a workaround, I have to repeat the same Edit-DirEnvRc steps over and over. Sometimes I add a dummy blank line, save, then delete the line, resave, and quit notepad.
I suspect the root cause has to do with posh-direnv's overly aggressive requirement for the file contents to be detected to change. In other words, we can improve posh-direnv accuracy by dropping the code that performs difference checks. Just always approve and apply the latest .psenvrc contents on disk, when notepad exits without an error status code.
Update
Even with NO changes to the .psenvrc file, posh-direnv often fails to load the configuration into the PowerShell environment. I very often have to manually execute Edit-DirEnvRc, add a blank line, save, delete the blank line, save, and quit notepad. In order for the existing .psenvrc contents take effect.
The text was updated successfully, but these errors were encountered:
I understand the need to avoid arbitrary code execution, but it would be good to have the ability to mark a particular directory as "trusted" so that any future changes would be approved automatically and run directly from the file.
direnv does this with direnv allow, and has no issue with silently ignoring file changes. Also, direnv loudly complains when there is an untrusted configuration file in the search path.
Hi,
posh-direnv often silently fails to apply .psenvrc changes. I go through the
Edit-DirEnvRc
workflow, and even close and relaunch PowerShell. But still, the changes fail to take effect.As a workaround, I have to repeat the same
Edit-DirEnvRc
steps over and over. Sometimes I add a dummy blank line, save, then delete the line, resave, and quit notepad.I suspect the root cause has to do with posh-direnv's overly aggressive requirement for the file contents to be detected to change. In other words, we can improve posh-direnv accuracy by dropping the code that performs difference checks. Just always approve and apply the latest .psenvrc contents on disk, when notepad exits without an error status code.
Update
Even with NO changes to the .psenvrc file, posh-direnv often fails to load the configuration into the PowerShell environment. I very often have to manually execute
Edit-DirEnvRc
, add a blank line, save, delete the blank line, save, and quit notepad. In order for the existing .psenvrc contents take effect.The text was updated successfully, but these errors were encountered: