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

"Open in Windows Terminal as administrator" context menu option #11024

Closed
tanuj-05 opened this issue Aug 24, 2021 · 6 comments
Closed

"Open in Windows Terminal as administrator" context menu option #11024

tanuj-05 opened this issue Aug 24, 2021 · 6 comments
Labels
Issue-Feature Complex enough to require an in depth planning process and actual budgeted, scheduled work. Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing.

Comments

@tanuj-05
Copy link

Open here as administrator option in context menu

When a user right clicks inside a folder, presently only "Open in Windows Terminal" is shown. But it will be better if a "open in Windows Terminal as Administrator" option is available also , how it is implemented for Powershell 7.

@tanuj-05 tanuj-05 added the Issue-Feature Complex enough to require an in depth planning process and actual budgeted, scheduled work. label Aug 24, 2021
@ghost ghost added Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting Needs-Tag-Fix Doesn't match tag requirements labels Aug 24, 2021
@unnati914
Copy link

could i work on this?

@tanuj-05
Copy link
Author

could i work on this?

yes sure

@unnati914
Copy link

hey.. what i was thinking was to add a m- in front of the file name that you want to run as admin .. Is my approach correct?

@unnati914
Copy link

[HKEY_CLASSES_ROOT\Directory\shell\OpenWTHereAsAdmin]
"HasLUAShield"=""
"MUIVerb"="Open in Windows Terminal as administrator"
"Extended"=""
"SubCommands"=""

[HKEY_CLASSES_ROOT\Directory\Shell\OpenWTHereAsAdmin\shell\001flyout]
"MUIVerb"="Default Profile"
"HasLUAShield"=""

[HKEY_CLASSES_ROOT\Directory\Shell\OpenWTHereAsAdmin\shell\001flyout\command]
@="powershell.exe -WindowStyle Hidden "Start-Process -Verb RunAs cmd.exe -ArgumentList @('/c','start wt.exe','-d','"""%V"""')""

[HKEY_CLASSES_ROOT\Directory\Shell\OpenWTHereAsAdmin\shell\002flyout]
"MUIVerb"="Command Prompt"
"Icon"="imageres.dll,-5324"

[HKEY_CLASSES_ROOT\Directory\Shell\OpenWTHereAsAdmin\shell\002flyout\command]
@="powershell.exe -WindowStyle Hidden "Start-Process -Verb RunAs cmd.exe -ArgumentList @('/c','start wt.exe','-p','"""Command Prompt"""','-d','"""%V"""')""

[HKEY_CLASSES_ROOT\Directory\Shell\OpenWTHereAsAdmin\shell\003flyout]
"MUIVerb"="PowerShell"
"HasLUAShield"=""
"Icon"="powershell.exe"

[HKEY_CLASSES_ROOT\Directory\Shell\OpenWTHereAsAdmin\shell\003flyout\command]
@="powershell.exe -WindowStyle Hidden "Start-Process -Verb RunAs cmd.exe -ArgumentList @('/c','start wt.exe','-p','"""Windows PowerShell"""','-d','"""%1"""')""

[HKEY_CLASSES_ROOT\Directory\Background\shell\OpenWTHereAsAdmin]
"HasLUAShield"=""
"MUIVerb"="Open in Windows Terminal as administrator"
"Extended"=""
"SubCommands"=""

[HKEY_CLASSES_ROOT\Directory\Background\Shell\OpenWTHereAsAdmin\shell\001flyout]
"MUIVerb"="Default Profile"
"HasLUAShield"=""

[HKEY_CLASSES_ROOT\Directory\Background\Shell\OpenWTHereAsAdmin\shell\001flyout\command]
@="powershell.exe -WindowStyle Hidden "Start-Process -Verb RunAs cmd.exe -ArgumentList @('/c','start wt.exe','-d','"""%V"""')""

[HKEY_CLASSES_ROOT\Directory\Background\Shell\OpenWTHereAsAdmin\shell\002flyout]
"MUIVerb"="Command Prompt"
"Icon"="imageres.dll,-5324"

[HKEY_CLASSES_ROOT\Directory\Background\Shell\OpenWTHereAsAdmin\shell\002flyout\command]
@="powershell.exe -WindowStyle Hidden "Start-Process -Verb RunAs cmd.exe -ArgumentList @('/c','start wt.exe','-p','"""Command Prompt"""','-d','"""%V"""')""

[HKEY_CLASSES_ROOT\Directory\Background\Shell\OpenWTHereAsAdmin\shell\003flyout]
"MUIVerb"="PowerShell"
"HasLUAShield"=""
"Icon"="powershell.exe"

[HKEY_CLASSES_ROOT\Directory\Background\Shell\OpenWTHereAsAdmin\shell\003flyout\command]
@="powershell.exe -WindowStyle
Or something like this?

@zadjii-msft
Copy link
Member

Thanks for the suggestion! This is actually already being tracked by another issue on our repo - please refer to #9903 for more discussion.

/dup #9903

More importantly, we'd like to also do #6111 first, so that people can configure how they want the context menu set up.

@ghost
Copy link

ghost commented Aug 24, 2021

Hi! We've identified this issue as a duplicate of another one that already exists on this Issue Tracker. This specific instance is being closed in favor of tracking the concern over on the referenced thread. Thanks for your report!

@ghost ghost closed this as completed Aug 24, 2021
@ghost ghost added Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing. and removed Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting Needs-Tag-Fix Doesn't match tag requirements labels Aug 24, 2021
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Issue-Feature Complex enough to require an in depth planning process and actual budgeted, scheduled work. Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing.
Projects
None yet
Development

No branches or pull requests

3 participants