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

Elevate Current Shell #100

Open
Jack-Chronicle opened this issue Sep 25, 2024 · 2 comments
Open

Elevate Current Shell #100

Jack-Chronicle opened this issue Sep 25, 2024 · 2 comments
Labels
Issue-Feature New feature or request. Complex enough to require planning and actual budgeted, scheduled work. Needs-Attention The core contributors need to come back around and look at this ASAP. Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting

Comments

@Jack-Chronicle
Copy link

Description of the new feature / enhancement

using the sudo command with no options elevates the current shell, without opening a new window if set to work inline
or add an option tag to do so, Linux/Unix systems use sudo su to do so

Scenario when this would be used?

When opening a non elevated command prompt, but later needing elevated permissions for multiple commands
Could also be used in individual tabs to allow you to go back from a non elevated tab when not needing elevated permissions and not cluttering the screen with multiple windows

Supporting information

No response

@Jack-Chronicle Jack-Chronicle added Issue-Feature New feature or request. Complex enough to require planning and actual budgeted, scheduled work. Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting labels Sep 25, 2024
@zadjii-msft
Copy link
Member

Why does sudo -E cmd (or sudo -E pwsh or whatever your shell is) not work for you/? It's a couple extra characters, but it does what you want while being more precise - copy the current environment into an elevated instance of the shell you want, in the current console.

(assuming of course you've set the sudo config to inline mode of course)

@microsoft-github-policy-service microsoft-github-policy-service bot added the Needs-Author-Feedback The original author of the issue/PR needs to come back and respond to something label Dec 6, 2024
@Jack-Chronicle
Copy link
Author

That seems to work well, I think it wasn't working for me when I made this issue or I was being picky.
It may have also been recently added during an update, I'm not sure.

Either way, seems to be okay now

@microsoft-github-policy-service microsoft-github-policy-service bot added Needs-Attention The core contributors need to come back around and look at this ASAP. and removed Needs-Author-Feedback The original author of the issue/PR needs to come back and respond to something labels Dec 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Issue-Feature New feature or request. Complex enough to require planning and actual budgeted, scheduled work. Needs-Attention The core contributors need to come back around and look at this ASAP. Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting
Projects
None yet
Development

No branches or pull requests

2 participants