Skip to content

Commit

Permalink
Create separate environ variable helpers
Browse files Browse the repository at this point in the history
  • Loading branch information
mglodack committed Feb 6, 2016
1 parent 7d9f555 commit 5fe979a
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/app/FakeLib/EnvironmentHelper.fs
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,15 @@ let environVars target =
e1.Key, e1.Value ]

/// Sets the environment variable with the given name
[<Obsolete "Please use setProcessEnvironVar">]
let setEnvironVar name value = Environment.SetEnvironmentVariable(name, value)

/// Sets the environment variable with the given name for the current user.
let setUserEnvironVar name value = Environment.SetEnvironmentVariable(name, value, EnvironmentVariableTarget.User)

/// Sets the environment variable with the given name for the current machine.
let setMachineEnvironVar name value = Environment.SetEnvironmentVariable(name, value, EnvironmentVariableTarget.Machine)

/// Sets the environment variable with the given name for the current process.
let setProcessEnvironVar name value = Environment.SetEnvironmentVariable(name, value, EnvironmentVariableTarget.Process)

Expand Down

0 comments on commit 5fe979a

Please sign in to comment.