It’s particularly frustrating because most Linux distributions fixed this a long time ago: thesudocommand.
It’s such a useful feature that it even inspiredone of the most famous XKCD comics.
Someone at Microsoft apparently noticed: sudo is now included in Windows.
There are three options here regarding how sudo runs.
By default, command will run in a new window.
Using the feature is straightforward: when running a command that requires administrator privileges, start withsudo.
You will see a pop-up asking to confirm.
ClickYesand the command will run as administrator.
That’s really it: just put sudo at the beginning of your commands to run as administrator.
Try it with your usual commands and see how you like it.
There are reasons Microsoft’s sudo may not work for you.
Maybe you’re not yet using the 24H2 version of Windows.
Maybe you’ve got the option to’t get sudo working with the applications you’re trying.
Or maybe you just want to quickly change your current session into an elevated session.
If so,gsudomight work better for you.