add switch to create desktop shortcut
This commit is contained in:
@@ -1,3 +1,6 @@
|
|||||||
|
## Create a desktop shortcut for WireGuard?
|
||||||
|
$CreateDesktopShortcut = $false
|
||||||
|
|
||||||
## Make sure we have an administrative token
|
## Make sure we have an administrative token
|
||||||
If ( IsAdmin )
|
If ( IsAdmin )
|
||||||
{
|
{
|
||||||
@@ -9,6 +12,8 @@ If ( IsAdmin )
|
|||||||
Catch { LogErr $_.Exception.Message }
|
Catch { LogErr $_.Exception.Message }
|
||||||
|
|
||||||
## Create shortcut on Public desktop
|
## Create shortcut on Public desktop
|
||||||
#Create-Shortcut -Path "${Env:Public}\Desktop\WireGuard.LNK" -TargetPath "${Env:ProgramFiles}\WireGuard\wireguard.exe" -Description "WireGuard: Fast, Modern, Secure VPN Tunnel"
|
If ( $CreateDesktopShortcut ) {
|
||||||
|
Create-Shortcut -Path "${Env:Public}\Desktop\WireGuard.LNK" -TargetPath "${Env:ProgramFiles}\WireGuard\wireguard.exe" -Description "WireGuard: Fast, Modern, Secure VPN Tunnel"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
Else { LogMsg "Must be an administrator to install WireGuard" }
|
Else { LogMsg "Must be an administrator to install WireGuard" }
|
||||||
Reference in New Issue
Block a user