I've been using Elevate
for awhile now.
It's description - This utility executes a command with UAC privilege elevation. This is useful for working inside command prompts or with batch files.
I copy the bin.x86-64\elevate.exe
from the .zip
into C:\Program Files\elevate
and add that path to my PATH
.
Then GitBash I can run something like elevate sc stop W3SVC
to turn off the IIS
service.
Running the command gives me the UAC
dialog, properly focused with keyboard control and upon accepting the dialog I return to my shell.