Environment variable - Path

Hello good folks.

Would anyone be so kind and help me with setting or appending a parth variable in Powershell?

Is there an elegant way to do it other than to use some function which edits a registry value? By elegant way I mean some new way in Powershell v5. :slight_smile:

Thank you very much.

Maybe you could use the .NET method SetEnvironmentVariable?

Call it from PowerShell:



Great suggestion,

thank you.

$Env:Path = $Env:Path + ";C:\SomeFolder

I found this solution also, if anybody ever needs it.