gsudo is a sudo
equivalent for Windows, with a similar user-experience as the original Unix/Linux sudo. Allows you to run a command (or re-launch your current shell) with elevated permissions, in the current console window or a new one.
Just prepend gsudo
(or the sudo
alias) to your command and it will run elevated. For PowerShell use this syntax: gsudo { ScriptBlock }
One UAC popup will appear each time. You can see less popups if you enable gsudo cache.
It detects your current shell and elevates your command as native shell commands. (Supports Cmd
, PowerShell
, WSL
, git-bash
, MinGW
, Cygwin
, Yori
, Take Command
, BusyBox
& NuShell
.)