mirror of
https://github.com/ChrisTitusTech/winutil
synced 2026-04-05 22:28:31 +00:00
Fix offline mode (#4153)
* Fix usb error on drive with no existing partitions * fix offline mode * Add offline banner
This commit is contained in:
@@ -9,7 +9,8 @@
|
||||
param (
|
||||
[string]$Config,
|
||||
[switch]$Run,
|
||||
[switch]$Noui
|
||||
[switch]$Noui,
|
||||
[switch]$Offline
|
||||
)
|
||||
|
||||
if ($Config) {
|
||||
@@ -27,6 +28,11 @@ if ($Noui) {
|
||||
$PARAM_NOUI = $true
|
||||
}
|
||||
|
||||
$PARAM_OFFLINE = $false
|
||||
if ($Offline) {
|
||||
$PARAM_OFFLINE = $true
|
||||
}
|
||||
|
||||
|
||||
if (!([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole]::Administrator)) {
|
||||
Write-Output "Winutil needs to be run as Administrator. Attempting to relaunch."
|
||||
|
||||
Reference in New Issue
Block a user