Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature: gsudo {scriptblock} easier syntax to elevate scriptblocks on powershell. #160

Closed
gerardog opened this issue Aug 31, 2022 · 0 comments · Fixed by #178
Closed

Feature: gsudo {scriptblock} easier syntax to elevate scriptblocks on powershell. #160

gerardog opened this issue Aug 31, 2022 · 0 comments · Fixed by #178

Comments

@gerardog
Copy link
Owner

Actual behaviour:

PS C:\> gsudo { echo 1 2 3 }
Debug: Command Line: gsudo -encodedCommand IABlAGMAaABvACAAMQAgADIAIAAzACAA -inputFormat xml -outputFormat text
Error: Invalid option: -encodedCommand

Should behave as:

PS C:\> gsudo pwsh { echo 1 2 3 }
1
2
3

This could be achievable by specially parsing -encodedCommand as the start of the command to elevate, instead of trying to see if it is a gsudo's own parameter token.

@gerardog gerardog linked a pull request Sep 14, 2022 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant