gsudo/sample-scripts
2023-08-21 13:32:58 -03:00
..
many-elevations-using-gsudo-cache.cmd Added sample usage scripts and docs 2023-08-21 13:32:58 -03:00
many-elevations-using-gsudo-cache.ps1 Added sample usage scripts and docs 2023-08-21 13:32:58 -03:00
readme.md Added sample usage scripts and docs 2023-08-21 13:32:58 -03:00
self-elevate-one-liner.cmd Added sample usage scripts and docs 2023-08-21 13:32:58 -03:00
self-elevate-without-gsudo.cmd Added sample usage scripts and docs 2023-08-21 13:32:58 -03:00
self-elevate.cmd Added sample usage scripts and docs 2023-08-21 13:32:58 -03:00
self-elevate.ps1 Added sample usage scripts and docs 2023-08-21 13:32:58 -03:00
silent-elevation-one-liner.cmd Added sample usage scripts and docs 2023-08-21 13:32:58 -03:00
silent-elevation.cmd Added sample usage scripts and docs 2023-08-21 13:32:58 -03:00

gsudo Sample Scripts

This folder contains sample scripts demonstrating how to use gsudo to elevate privileges on a Windows machine. The provided scripts include:

  1. Script Self-Elevation: A technique to ensure that the current script is running elevated, by detecting when it is not, and elevating itself. More details can be found in the gsudo documentation on script self-elevation.

  2. Many Elevations Using gsudo Cache:

  3. Don't show an UAC pop-up: Perform an elevated admin task if and only if it can be done without an interactive UAC pop-up. (i.e. when already elevated or gsudo cache is active)

These scripts are examples and should be used with caution. Always review and understand the code you are executing on your system.