-
-
Save The-Running-Dev/8f9a480132e968d651b321c5e085d438 to your computer and use it in GitHub Desktop.
Modify Link to run as admin
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$linkFilePath = "C:\Users\$([Environment]::UserName)\Desktop\WindowsTerminal.lnk" | |
$bytes = [System.IO.File]::ReadAllBytes($linkFilePath) | |
$bytes[0x15] = $bytes[0x15] -bor 0x20 #set byte 21 (0x15) bit 6 (0x20) ON | |
[System.IO.File]::WriteAllBytes($linkFilePath, $bytes) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment