From 1add44f6ce82714dba659be2504a96098ce3ed5b Mon Sep 17 00:00:00 2001 From: Matthew Stratford Date: Thu, 29 Oct 2020 19:24:00 +0000 Subject: [PATCH] Fix uninstaller to 100% clear up. --- install/uninstall.bat | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/install/uninstall.bat b/install/uninstall.bat index 2b66ee1..d0dd0e0 100644 --- a/install/uninstall.bat +++ b/install/uninstall.bat @@ -1,11 +1,15 @@ set service_name="BAPSicle" -cd %~dp0\nssm -nssm stop %service_name% -nssm remove %service_name% confirm -sc.exe delete %service_name% +: We can't 'nssm stop because' we're about to delete it. +: The file will remain open, so you'll get access denied. +net stop %service_name% +sc delete %service_name% + +: We cd out of the folder, just in case we're about to delete +: out PWD. +cd \ +rmdir "C:\Program Files\BAPSicle\" /q /s -del "C:\Program Files\BAPSicle\" /q /s /f PAUSE \ No newline at end of file