Command.cs
/// <summary>
/// Check if some path is stored into user PATH variable
/// </summary>
/// <param name="value">value to check agains</param>
/// <returns>Returns true if it is defined in to the PATH variable, false if it does not</returns>
Check if some path is stored into user PATH variable
Check if some path is stored into user PATH variable
protected bool DoesExistInPath(string value)
        {
            var name = "PATH";
            var scope = EnvironmentVariableTarget.User;
            var pathValue = Environment.GetEnvironmentVariable(name, scope);
            return pathValue.Split(';').Contains(value);
        }
protected bool DoesExistInPath ( string value ) { var name = " " ; var scope = EnvironmentVariableTarget . User ; var pathValue = Environment . GetEnvironmentVariable ( name , scope ) ; return pathValue . Split ( ' ' ) . Contains ( value ) ; }
Check if some path is stored into user PATH variable
Check if some path is stored into user PATH variable
Returns true if it is defined in to the PATH variable, false if it does not
Returns true if it is defined in to the PATH variable false if it does not
value
string
value to check agains
value to check agains