[Launch]
ProgramExecutable="SecureEraser\sEraser.exe"
WorkingDirectory=%PAL:AppDir%\SecureEraser
RunAsAdmin=force
SinglePortableAppInstance=true
DirectoryMoveOK=yes

[Activate]
Registry=true

[RegistryValueWrite]
HKCU\Software\ASCOMP\Secure Eraser\CheckUpdate=REG_DWORD:0
HKCU\Software\ASCOMP\Secure Eraser\ReportsFolder=REG_SZ:%PAL:LastDrive%%PAL:PackagePartialDir%\Data\Reports\

[RegistryKeys]
SecureEraser="HKCU\Software\ASCOMP\Secure Eraser"

[RegistryCleanupIfEmpty]
1=HKCU\Software\ASCOMP

[DirectoriesMove]
SecureEraser="%AppData%\ASCOMP Software\Secure Eraser"

[FileWrite1]
Type=Replace
File=%PAL:DataDir%\settings\SecureEraser.reg
Find=%PAL:LastDrive%%PAL:LastPackagePartialDir:DoubleBackslash%\\
Replace=%PAL:Drive%%PAL:PackagePartialDir:DoubleBackslash%\\

[FileWrite2]
Type=Replace
File=%PAL:DataDir%\settings\SecureEraser.reg
Find=%PAL:LastPortableAppsBaseDir:DoubleBackslash%\\
Replace=%PAL:PortableAppsBaseDir:DoubleBackslash%\\

[FileWrite3]
Type=Replace
File=%PAL:DataDir%\settings\SecureEraser.reg
Find=%PAL:LastDrive%\\
Replace=%PAL:Drive%\\