[packaging] (Windows installer) Add registry entry for autostart and cleanup on uninstall
This commit is contained in:
@@ -81,6 +81,15 @@ var dataDir
|
||||
|
||||
SimpleSC::SetServiceDescription "PortmasterCore" "Portmaster Application Firewall - Core Service"
|
||||
|
||||
;
|
||||
; Auto start the UI
|
||||
;
|
||||
DetailPrint "Creating registry entry for autostart"
|
||||
WriteRegStr HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\Run" "Portmaster" '"$INSTDIR\portmaster.exe" --with-prompts --with-notifications --background'
|
||||
|
||||
;
|
||||
; MIGRATION FROM PMv1 TO PMv2
|
||||
;
|
||||
StrCpy $oldInstallationDir "$COMMONPROGRAMDATA\Safing\Portmaster"
|
||||
StrCpy $dataDir "$COMMONPROGRAMDATA\Portmaster"
|
||||
|
||||
@@ -168,6 +177,10 @@ var dataDir
|
||||
Delete /REBOOTOK "$INSTDIR\assets.zip"
|
||||
RMDir /r /REBOOTOK "$INSTDIR"
|
||||
|
||||
; remove the registry entry for the autostart
|
||||
DetailPrint "Removing registry entry for autostart"
|
||||
DeleteRegKey HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\Run"
|
||||
|
||||
; delete data files
|
||||
Delete /REBOOTOK "$COMMONPROGRAMDATA\Portmaster\databases\history.db"
|
||||
RMDir /r /REBOOTOK "$COMMONPROGRAMDATA\Portmaster\databases\cache"
|
||||
|
||||
Reference in New Issue
Block a user