Skip to content

Commit eb90442

Browse files
authored
auto-dark-mode-np: Fix installation
related: ScoopInstaller/Extras#9026 related: ScoopInstaller/Scoop#5065
1 parent cc82099 commit eb90442

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

bucket/auto-dark-mode-np.json

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,17 @@
88
"notes": "Settings need to be reapplied after updating.",
99
"installer": {
1010
"script": [
11+
"if (!(is_admin)) { error \"$app requires admin rights to $cmd\"; break }",
1112
"if ([Environment]::OSVersion.Version.Major -lt 10) { error \"$app only supports Windows 10\"; break }",
12-
"Invoke-ExternalCommand \"$dir\\setup.exe\" -ArgumentList @('/SP-', '/VERYSILENT', '/SUPPRESSMSGBOXES', '/NORESTART', \"/DIR=`\"$dir`\"\") -RunAs | Out-Null",
13+
"Start-Process \"$dir\\setup.exe\" -ArgumentList @('/SP-', '/VERYSILENT', '/SUPPRESSMSGBOXES', '/NORESTART', \"/DIR=`\"$dir`\"\") -Wait -Verb RunAs | Out-Null",
1314
"Remove-Item \"$dir\\setup.exe\""
1415
]
1516
},
1617
"uninstaller": {
17-
"script": "Invoke-ExternalCommand \"$dir\\unins000.exe\" -ArgumentList @('/VERYSILENT', '/SUPPRESSMSGBOXES', '/NORESTART') -RunAs | Out-Null"
18+
"script": [
19+
"if (!(is_admin)) { error \"$app requires admin rights to $cmd\"; break }",
20+
"Invoke-ExternalCommand \"$dir\\unins000.exe\" -ArgumentList @('/VERYSILENT', '/SUPPRESSMSGBOXES', '/NORESTART') -RunAs | Out-Null"
21+
]
1822
},
1923
"checkver": "github",
2024
"autoupdate": {

0 commit comments

Comments
 (0)