Update StackMonkey.ps1

This commit is contained in:
2025-07-02 21:53:35 -04:00
parent 201a760041
commit 81f0de3d48

View File

@@ -221,7 +221,7 @@
# Attempt to uninstall all versions of SVSMSP # Attempt to uninstall all versions of SVSMSP
try { try {
Uninstall-Module -Name SVSMSP -AllVersions -Force -Confirm:$false -ErrorAction Stop Uninstall-Module -Name SVSMSP -AllVersions -Force -ErrorAction Stop
Write-LogHybrid "SVSMSP module uninstalled from system." "Success" "SVSModule" Write-LogHybrid "SVSMSP module uninstalled from system." "Success" "SVSModule"
} }
catch { catch {
@@ -237,7 +237,7 @@
# Remove the custom repository if registered # Remove the custom repository if registered
if (Get-PSRepository -Name SVS_Repo -ErrorAction SilentlyContinue) { if (Get-PSRepository -Name SVS_Repo -ErrorAction SilentlyContinue) {
try { try {
Unregister-PSRepository -Name SVS_Repo -Confirm:$false -ErrorAction Stop Unregister-PSRepository -Name SVS_Repo -ErrorAction Stop
Write-LogHybrid "SVS_Repo repository unregistered." "Success" "SVSModule" Write-LogHybrid "SVS_Repo repository unregistered." "Success" "SVSModule"
} }
catch { catch {
@@ -248,7 +248,7 @@
# Finally, remove it from the current session if loaded # Finally, remove it from the current session if loaded
if (Get-Module -Name SVSMSP) { if (Get-Module -Name SVSMSP) {
try { try {
Remove-Module SVSMSP -Force -Confirm:$false -ErrorAction Stop Remove-Module SVSMSP -Force -ErrorAction Stop
Write-LogHybrid "SVSMSP module removed from current session." "Success" "SVSModule" Write-LogHybrid "SVSMSP module removed from current session." "Success" "SVSModule"
} }
catch { catch {