Warp icon indicating copy to clipboard operation
Warp copied to clipboard

Ability to run Warp with administrator rights on Windows

Open Harquell opened this issue 8 months ago • 17 comments

Pre-submit Checks

Describe the solution you'd like?

Running a terminal session with administrator rights on Windows is a requirement for some tasks.

Right now, I wasn't able to find any way of running either warp as an admin with all sessions within the window running with elevated privileges nor any way of running a tab as an admin.

Is your feature request related to a problem? Please describe.

I can't use Warp as my main terminal as long as this is not implemented on windows. Unlike any unix based system, you can sudo things or change the user of the session.

On windows this is simply not doable. It makes it impossible to run system wide scripts within Warp.

Additional context

(For example, the Windows Terminal can be run either as current user or admin as shown in the screenshot) Image

Operating system (OS)

Windows

How important is this feature to you?

4

Warp Internal (ignore) - linear-label:39cc6478-1249-4ee7-950b-c428edfeecd1

None

Harquell avatar Apr 04 '25 17:04 Harquell

Hi @Harquell You can currently right-click on the Warp icon and run as administrator. To do this by default, you can right-click > open file location to see the shortcut, then right-click the shortcut > properties > compatibility > Run this program as an administrator.

https://github.com/user-attachments/assets/53d07219-10c8-4b4f-a3bc-7199d1f922f6

Warp will not show the "Administrator" on the tab, but you can verify that it's an elevated powershell with the following command:

[Security.Principal.WindowsIdentity]::GetCurrent().Claims | Where-Object { $_.Value -eq "S-1-5-32-544" } | Select-Object -First 1 | ForEach-Object { Write-Output "PowerShell is running with Administrator privileges" }; if (-not $?) { Write-Output "PowerShell is running without Administrator privileges" }

I hope this helps! Please let me know if this fits your use case, if not please explain how what you want is different.

To anyone else interested in this feature, please add a 👍 to the original post at the top to signal that you want this feature, and subscribe if you'd like to be notified.

dannyneira avatar Apr 04 '25 21:04 dannyneira

Hi @Harquell You can currently right-click on the Warp icon and run as administrator. To do this by default, you can right-click > open file location to see the shortcut, then right-click the shortcut > properties > compatibility > Run this program as an administrator. CleanShot.2025-04-04.at.15.48.28.mp4

Warp will not show the "Administrator" on the tab, but you can verify that it's an elevated powershell with the following command:

[Security.Principal.WindowsIdentity]::GetCurrent().Claims | Where-Object { $_.Value -eq "S-1-5-32-544" } | Select-Object -First 1 | ForEach-Object { Write-Output "PowerShell is running with Administrator privileges" }; if (-not $?) { Write-Output "PowerShell is running without Administrator privileges" }

I hope this helps! Please let me know if this fits your use case, if not please explain how what you want is different.

To anyone else interested in this feature, please add a 👍 to the original post at the top to signal that you want this feature, and subscribe if you'd like to be notified.

I don't think this is the case. Opening the start menu and then right-click to choose to run as administrator is quite inconvenient, while running under administrator priviledge by default is unafe and improper. I think it is better to add an option in Warp's taskbar context menu

Image

or somewhere in the Warp window.

lemon-sundae avatar Apr 05 '25 10:04 lemon-sundae

Hi @dannyneira Thanks for the reply.

Hi @Harquell You can currently right-click on the Warp icon and run as administrator. To do this by default, you can right-click > open file location to see the shortcut, then right-click the shortcut > properties > compatibility > Run this program as an administrator.

While warp is probably running with administrator privileges, the shell is still not elevated. When trying to run a chocolatey upgrade command for example, I get the following error :

Image

Harquell avatar Apr 07 '25 08:04 Harquell

@lemon-sundae heard @Harquell, I dont think we can add that option of "Run as Administrator" to the taskbar, but I imagine it could be in Warp, like w/Windows Terminal.

Image

As a stopgap, I recommend you look into Sudo for Windows, this may help with the use case of elevating for specific commands, but not by default.

dannyneira avatar Apr 07 '25 15:04 dannyneira

@lemon-sundae heard @Harquell, I dont think we can add that option of "Run as Administrator" to the taskbar, but I imagine it could be in Warp, like w/Windows Terminal.

This is good, thanks.

As a stopgap, I recommend you look into Sudo for Windows, this may help with the use case of elevating for specific commands, but not by default.

I am already using sudo for Windows actually, but it does not work well with Warp. When sudo-ed, it just run the program seperately and the new window automatically closes after it's done, just like double-clicking a command line program in the explorer. Which means I cannot see the outputs. I wonder if there is a possible sulution to enhance this behavior.

lemon-sundae avatar Apr 07 '25 16:04 lemon-sundae

@lemon-sundae in the Windows System > For Developers > Sudo settings, configure the applications to run Inline. This should allow them to run/stay within Warp so that you see the output.

Image

dannyneira avatar Apr 07 '25 16:04 dannyneira

Reopening a Warp window can solve the admin-privilege issue but after an operation finishes the privilege's gone. So the request is justified and I second!

ouzmno avatar Apr 25 '25 08:04 ouzmno

I don't think this is the case. Opening the start menu and then right-click to choose to run as administrator is quite inconvenient, while running under administrator priviledge by default is unafe and improper. I think it is better to add an option in Warp's taskbar context menu

Image or somewhere in the Warp window.

You can Shift click the icon on the task bar to run as administrator.

Bocephus avatar May 13 '25 12:05 Bocephus

ok, at least I got the direction

alexdolbun avatar Jun 14 '25 14:06 alexdolbun

this would be really nice, though i'd like to avoid giving the entire warp process admin privileges of possible, not sure if that's doable, but having to open a powershell in another window or windows terminal to run some commands really defeats the purpose and limits the context available to warp.

sterling000 avatar Jun 25 '25 21:06 sterling000

i'd like to avoid giving the entire warp process admin privileges of possible, not sure if that's doable

@sterling000 Do you mean windows sudo? Google it.

lemon-sundae avatar Jun 25 '25 22:06 lemon-sundae

i'd like to avoid giving the entire warp process admin privileges of possible, not sure if that's doable

@sterling000 Do you mean windows sudo? Google it.

No, i don't mean that, I read the rest of the thread and saw people suggest it, i would like to not have to install another 3rd party app, i'd prefer it to come with Warp.

sterling000 avatar Jun 25 '25 22:06 sterling000

i would like to not have to install another 3rd party app

@sterling000 There may be a confusion. Sudo for Windows is a new feature introduced in Windows 11 Insider Preview Build 26052 that allows users to run elevated commands directly from an unelevated console session.

lemon-sundae avatar Jun 25 '25 22:06 lemon-sundae

i would like to not have to install another 3rd party app

@sterling000 There may be a confusion. Sudo for Windows is a new feature introduced in Windows 11 Insider Preview Build 26052 that allows users to run elevated commands directly from an unelevated console session.

Ahh, thanks, that makes a slight difference. I'm not on insider previews yet, but i'll keep my eye out for that

sterling000 avatar Jun 25 '25 22:06 sterling000

I'm not on insider previews yet

@sterling000 😹 Sorry for another confusion but this feature is already in the stable release of Windows 11. Check it in your settings. If this option cannot be found try to upgrade the system. You may check Microsoft's documents for more details.

lemon-sundae avatar Jun 25 '25 22:06 lemon-sundae

hey folks, thanks for your patience, this isnt on the roadmap right now with no eta on release of the feature, but if you're interested in this feature, please add a 👍 to the original post at the top to signal that you want this feature, and subscribe if you'd like to be notified.

dannyneira avatar Nov 25 '25 20:11 dannyneira