mirror of
https://github.com/aphrody-labs/PowerShell.git
synced 2026-10-17 12:45:47 +00:00
Fix command-line parser to support --parameters
This commit is contained in:
1 parent
c4bfc52c76
commit
d8b2d1fb0e
1 file changed
+6
@@ -365,6 +365,12 @@ namespace Microsoft.PowerShell
|
||||
|
||||
switchKey = switchKey.Substring(1);
|
||||
|
||||
// chop off the second dash so we're agnostic wrt specifying - or --
|
||||
if (SpecialCharacters.IsDash(switchKey[0]))
|
||||
{
|
||||
switchKey = switchKey.Substring(1);
|
||||
}
|
||||
|
||||
if (MatchSwitch(switchKey, "help", "h") || MatchSwitch(switchKey, "?", "?"))
|
||||
{
|
||||
showHelp = true;
|
||||
|
||||
Reference in new issue
Block a user