This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
userspace:notepad2 [2012/07/12 14:09] SisterOfMercy |
userspace:notepad2 [2014/05/28 22:28] SisterOfMercy |
||
---|---|---|---|
Line 6: | Line 6: | ||
During the installation a notepad2.ini is copied to the installation directory of notepad2, which redirects notepad2 to use the ini file in the Application Data folder of the user. This way each user can mess with his own settings. \\ | During the installation a notepad2.ini is copied to the installation directory of notepad2, which redirects notepad2 to use the ini file in the Application Data folder of the user. This way each user can mess with his own settings. \\ | ||
+ | |||
+ | ==== %scriptpath%\files\programfiles\notepad2.ini ==== | ||
+ | |||
+ | <code winst> | ||
+ | [Notepad2] | ||
+ | Notepad2.ini=%APPDATA%\Notepad2.ini | ||
+ | </ | ||
+ | |||
+ | ==== %scriptpath%\files\appdata\notepad2.ini ==== | ||
+ | |||
+ | <code winst> | ||
+ | [Notepad2] | ||
+ | [Settings] | ||
+ | SaveSettings=0 | ||
+ | SaveRecentFiles=0 | ||
+ | SaveFindReplace=0 | ||
+ | CloseFind=0 | ||
+ | CloseReplace=0 | ||
+ | NoFindWrap=0 | ||
+ | OpenWithDir=%USERPROFILE%\Desktop | ||
+ | Favorites=%CSIDL: | ||
+ | PathNameFormat=2 | ||
+ | WordWrap=0 | ||
+ | WordWrapMode=0 | ||
+ | WordWrapIndent=0 | ||
+ | WordWrapSymbols=22 | ||
+ | ShowWordWrapSymbols=0 | ||
+ | MatchBraces=1 | ||
+ | AutoCloseTags=0 | ||
+ | HighlightCurrentLine=0 | ||
+ | AutoIndent=1 | ||
+ | ShowIndentGuides=0 | ||
+ | TabsAsSpaces=0 | ||
+ | TabIndents=1 | ||
+ | BackspaceUnindents=0 | ||
+ | TabWidth=8 | ||
+ | IndentWidth=0 | ||
+ | MarkLongLines=0 | ||
+ | LongLinesLimit=72 | ||
+ | LongLineMode=1 | ||
+ | ShowSelectionMargin=0 | ||
+ | ShowLineNumbers=1 | ||
+ | ViewWhiteSpace=0 | ||
+ | ViewEOLs=0 | ||
+ | DefaultEncoding=0 | ||
+ | SkipUnicodeDetection=0 | ||
+ | LoadASCIIasUTF8=0 | ||
+ | NoEncodingTags=0 | ||
+ | DefaultEOLMode=0 | ||
+ | FixLineEndings=1 | ||
+ | FixTrailingBlanks=0 | ||
+ | PrintHeader=1 | ||
+ | PrintFooter=0 | ||
+ | PrintColorMode=3 | ||
+ | PrintZoom=10 | ||
+ | PrintMarginLeft=2000 | ||
+ | PrintMarginTop=2000 | ||
+ | PrintMarginRight=2000 | ||
+ | PrintMarginBottom=2000 | ||
+ | SaveBeforeRunningTools=0 | ||
+ | FileWatchingMode=0 | ||
+ | ResetFileWatching=1 | ||
+ | EscFunction=0 | ||
+ | AlwaysOnTop=0 | ||
+ | MinimizeToTray=0 | ||
+ | TransparentMode=0 | ||
+ | ToolbarButtons=1 2 3 4 0 5 6 0 7 8 9 0 10 11 0 12 0 13 14 0 15 16 0 17 | ||
+ | ShowToolbar=1 | ||
+ | ShowStatusbar=1 | ||
+ | EncodingDlgSizeX=256 | ||
+ | EncodingDlgSizeY=262 | ||
+ | RecodeDlgSizeX=256 | ||
+ | RecodeDlgSizeY=262 | ||
+ | FileMRUDlgSizeX=412 | ||
+ | FileMRUDlgSizeY=376 | ||
+ | OpenWithDlgSizeX=384 | ||
+ | OpenWithDlgSizeY=386 | ||
+ | FavoritesDlgSizeX=334 | ||
+ | FavoritesDlgSizeY=316 | ||
+ | FindReplaceDlgPosX=0 | ||
+ | FindReplaceDlgPosY=0 | ||
+ | [Window] | ||
+ | 1600x900 PosX=744 | ||
+ | 1600x900 PosY=16 | ||
+ | 1600x900 SizeX=840 | ||
+ | 1600x900 SizeY=840 | ||
+ | 1600x900 Maximized=0 | ||
+ | [Custom Colors] | ||
+ | 01=#000000 | ||
+ | 02=#0A246A | ||
+ | 03=#3A6EA5 | ||
+ | 04=#003CE6 | ||
+ | 05=#006633 | ||
+ | 06=#608020 | ||
+ | 07=#648000 | ||
+ | 08=#A46000 | ||
+ | 09=#FFFFFF | ||
+ | 10=#FFFFE2 | ||
+ | 11=#FFF1A8 | ||
+ | 12=#FFC000 | ||
+ | 13=#FF4000 | ||
+ | 14=#C80000 | ||
+ | 15=#B000B0 | ||
+ | 16=#B28B40 | ||
+ | [Styles] | ||
+ | Use2ndDefaultStyle=0 | ||
+ | DefaultScheme=0 | ||
+ | AutoSelect=1 | ||
+ | SelectDlgSizeX=304 | ||
+ | SelectDlgSizeY=324 | ||
+ | [Recent Files] | ||
+ | [Recent Find] | ||
+ | [Recent Replace] | ||
+ | </ | ||
==== control file ==== | ==== control file ==== | ||
Line 11: | Line 125: | ||
<code winst> | <code winst> | ||
[Package] | [Package] | ||
- | version: | + | version: |
depends: | depends: | ||
incremental: | incremental: | ||
Line 18: | Line 132: | ||
type: localboot | type: localboot | ||
id: notepad2 | id: notepad2 | ||
- | name: Notepad2 Editor | + | name: Notepad2 |
- | description: | + | description: |
advice: | advice: | ||
version: 4.2.25 | version: 4.2.25 | ||
- | priority: | + | priority: |
licenseRequired: | licenseRequired: | ||
productClasses: | productClasses: | ||
- | setupScript: | + | setupScript: |
- | uninstallScript: | + | uninstallScript: |
updateScript: | updateScript: | ||
alwaysScript: | alwaysScript: | ||
Line 32: | Line 146: | ||
customScript: | customScript: | ||
userLoginScript: | userLoginScript: | ||
- | |||
- | [ProductProperty] | ||
- | type: unicode | ||
- | name: install_architecture | ||
- | multivalue: False | ||
- | editable: True | ||
- | description: | ||
- | values: ["32 only", "64 only", " | ||
- | default: [" | ||
[Changelog] | [Changelog] | ||
Line 47: | Line 152: | ||
* Initial package | * Initial package | ||
- | -- ICT <ict@your-mom.com> Thu, 21 Jun 2012 03:03:14 +0000 | + | -- ICT <ict@gcecad-service.nl> Thu, 03 Apr 2014 19:01:31 +0000 |
- | </ | + | </ |
- | ==== setup.ins ==== | + | ==== setup3264.ins ==== |
<code winst> | <code winst> | ||
+ | ; Copyright (c) uib gmbh (www.uib.de) | ||
+ | ; This sourcecode is owned by uib | ||
+ | ; and published under the Terms of the General Public License. | ||
+ | ; credits: http:// | ||
+ | ; | ||
+ | ; License Management removed | ||
+ | |||
+ | |||
[Actions] | [Actions] | ||
requiredWinstVersion >= " | requiredWinstVersion >= " | ||
+ | ;DefVar $MsiId32$ | ||
+ | ;DefVar $UninstallProgram32$ | ||
+ | ;DefVar $MsiId64$ | ||
+ | ;DefVar $UninstallProgram64$ | ||
DefVar $LogDir$ | DefVar $LogDir$ | ||
DefVar $ProductId$ | DefVar $ProductId$ | ||
Line 64: | Line 181: | ||
DefVar $ExitCode$ | DefVar $ExitCode$ | ||
DefVar $INST_SystemType$ | DefVar $INST_SystemType$ | ||
- | DefVar $INST_architecture$ | + | ;DefVar $INST_architecture$ |
+ | DefVar $INST_MsVersion$ | ||
+ | set $INST_MsVersion$ = GetMsVersionInfo | ||
Set $INST_SystemType$ = GetSystemType | Set $INST_SystemType$ = GetSystemType | ||
- | set $INST_architecture$ = GetProductProperty(" | + | ;set $INST_architecture$ = GetProductProperty(" |
Set $LogDir$ = " | Set $LogDir$ = " | ||
Line 77: | Line 196: | ||
; no white space use ' | ; no white space use ' | ||
Set $ProductId$ | Set $ProductId$ | ||
- | Set $MinimumSpace$ | + | Set $MinimumSpace$ |
; the path were we find the product after the installation | ; the path were we find the product after the installation | ||
Set $InstallDir32$ | Set $InstallDir32$ | ||
Line 87: | Line 206: | ||
isFatalError | isFatalError | ||
; Stop process and set installation status to failed | ; Stop process and set installation status to failed | ||
- | else | ||
- | comment "Show product picture" | ||
- | ShowBitmap " | ||
- | comment " | ||
- | |||
- | if (($INST_SystemType$ = "x86 System" | ||
- | Message " | ||
- | comment "Start setup program" | ||
- | Winbatch_install_32 | ||
- | Sub_check_exitcode | ||
- | comment "Copy files" | ||
- | Files_install_32 /32Bit | ||
- | comment "Copy files to all userprofiles" | ||
- | Files_install_allusers / | ||
endif | endif | ||
+ | if $INST_MsVersion$ < " | ||
+ | LogError " | ||
+ | isFatalError | ||
+ | endif | ||
+ | |||
+ | comment "Show product picture" | ||
+ | ShowBitmap " | ||
- | if ($INST_SystemType$ = "64 Bit System" | + | if FileExists("%ScriptPath%\delsub3264.ins") |
- | Message " | + | comment " |
- | comment " | + | Sub "%ScriptPath%\delsub3264.ins" |
- | Winbatch_install_64 | + | endif |
- | Sub_check_exitcode | + | |
- | comment | + | |
- | Files_install_64 /64Bit | + | |
- | comment "Copy files to all userprofiles" | + | |
- | Files_install_allusers / | + | |
- | endif | + | |
+ | comment " | ||
+ | |||
+ | if ($INST_SystemType$ = "x86 System" | ||
+ | ;and ($INST_architecture$ = " | ||
+ | Message " | ||
+ | comment "Start setup program" | ||
+ | Winbatch_install_32 | ||
+ | Sub_check_exitcode | ||
+ | comment "Copy files" | ||
+ | Files_install_32 /32Bit | ||
+ | comment "Patch Registry" | ||
+ | Registry_install /32Bit | ||
+ | comment "Copy files to all userprofiles" | ||
+ | Files_install_allusers / | ||
+ | comment " | ||
+ | LinkFolder_install | ||
endif | endif | ||
+ | |||
+ | if ($INST_SystemType$ = "64 Bit System" | ||
+ | ;and (($INST_architecture$ = " | ||
+ | Message " | ||
+ | comment "Start setup program" | ||
+ | Winbatch_install_64 | ||
+ | Sub_check_exitcode | ||
+ | comment "Copy files" | ||
+ | Files_install_64 /64Bit | ||
+ | comment "Patch Registry" | ||
+ | Registry_install /64Bit | ||
+ | comment "Copy files to all userprofiles" | ||
+ | Files_install_allusers / | ||
+ | comment " | ||
+ | LinkFolder_install | ||
+ | endif | ||
+ | |||
[Winbatch_install_32] | [Winbatch_install_32] | ||
Line 131: | Line 270: | ||
copy -s " | copy -s " | ||
+ | [Registry_install] | ||
+ | ; Example of setting some values of an registry key: | ||
+ | ; | ||
+ | ; openkey [HKEY_LOCAL_MACHINE\Software\$ProductId$] | ||
+ | ; set " | ||
+ | ; set " | ||
+ | ; set " | ||
+ | [LinkFolder_install] | ||
+ | ; Example of deleting a folder from AllUsers startmenu: | ||
+ | ; | ||
+ | ; set_basefolder common_programs | ||
+ | ; delete_subfolder $ProductId$ | ||
+ | ; | ||
+ | ; Example of creating an shortcut to the installed exe in AllUsers startmenu: | ||
+ | ; | ||
+ | ; set_basefolder common_programs | ||
+ | ; set_subfolder $ProductId$ | ||
+ | ; | ||
+ | ; set_link | ||
+ | ; name: $ProductId$ | ||
+ | ; target: <path to the program> | ||
+ | ; parameters: | ||
+ | ; working_dir: | ||
+ | ; icon_file: | ||
+ | ; icon_index: | ||
+ | ; end_link | ||
+ | ; | ||
+ | ; Example of creating an shortcut to the installed exe on AllUsers desktop: | ||
+ | ; | ||
+ | ; set_basefolder common_desktopdirectory | ||
+ | ; set_subfolder "" | ||
+ | ; | ||
+ | ; set_link | ||
+ | ; name: $ProductId$ | ||
+ | ; target: <path to the program> | ||
+ | ; parameters: | ||
+ | ; working_dir: | ||
+ | ; icon_file: <path to icon file> | ||
+ | ; icon_index: | ||
+ | ; end_link | ||
Line 164: | Line 343: | ||
</ | </ | ||
- | ==== uninstall.ins ==== | + | ==== uninstall3264.ins ==== |
- | <code winst> | + | <code winst>; Copyright (c) uib gmbh (www.uib.de) |
- | ; Copyright (c) uib gmbh (www.uib.de) | + | |
; This sourcecode is owned by uib gmbh | ; This sourcecode is owned by uib gmbh | ||
; and published under the Terms of the General Public License. | ; and published under the Terms of the General Public License. | ||
; credits: http:// | ; credits: http:// | ||
+ | ; | ||
+ | ; License Management removed | ||
[Actions] | [Actions] | ||
requiredWinstVersion >= " | requiredWinstVersion >= " | ||
- | DefVar $UninstallProgram32$ | + | ;DefVar $MsiId32$ |
- | DefVar $UninstallProgram64$ | + | ;DefVar $UninstallProgram32$ |
+ | ;DefVar $MsiId64$ | ||
+ | ;DefVar $UninstallProgram64$ | ||
DefVar $LogDir$ | DefVar $LogDir$ | ||
DefVar $ExitCode$ | DefVar $ExitCode$ | ||
Line 183: | Line 365: | ||
DefVar $InstallDir64$ | DefVar $InstallDir64$ | ||
DefVar $INST_SystemType$ | DefVar $INST_SystemType$ | ||
- | DefVar $INST_architecture$ | + | ;DefVar $INST_architecture$ |
Set $INST_SystemType$ = GetSystemType | Set $INST_SystemType$ = GetSystemType | ||
- | set $INST_architecture$ = GetProductProperty(" | + | ;set $INST_architecture$ = GetProductProperty(" |
+ | |||
Set $LogDir$ = " | Set $LogDir$ = " | ||
Line 196: | Line 380: | ||
Set $InstallDir64$ | Set $InstallDir64$ | ||
; ---------------------------------------------------------------- | ; ---------------------------------------------------------------- | ||
+ | |||
comment "Show product picture" | comment "Show product picture" | ||
ShowBitmap " | ShowBitmap " | ||
+ | |||
+ | Message " | ||
+ | |||
+ | if FileExists(" | ||
+ | comment "Start uninstall sub section" | ||
+ | Sub " | ||
+ | endif | ||
+ | </ | ||
+ | |||
+ | ==== delsub3264.ins ==== | ||
+ | |||
+ | <code winst> | ||
+ | ; Copyright (c) uib gmbh (www.uib.de) | ||
+ | ; This sourcecode is owned by uib gmbh | ||
+ | ; and published under the Terms of the General Public License. | ||
+ | ; credits: http:// | ||
+ | ; | ||
+ | ; License Management removed | ||
+ | |||
+ | DefVar $UninstallProgram32$ | ||
+ | DefVar $UninstallProgram64$ | ||
Set $UninstallProgram32$ = $InstallDir32$ + " | Set $UninstallProgram32$ = $InstallDir32$ + " | ||
Set $UninstallProgram64$ = $InstallDir64$ + " | Set $UninstallProgram64$ = $InstallDir64$ + " | ||
- | | + | |
- | if (($INST_SystemType$ = "x86 System" | + | if ($INST_SystemType$ = "x86 System" |
- | Message " | + | ;and ($INST_architecture$ = " |
+ | Message " | ||
if FileExists($UninstallProgram32$) | if FileExists($UninstallProgram32$) | ||
Line 211: | Line 418: | ||
sub_check_exitcode | sub_check_exitcode | ||
endif | endif | ||
+ | |||
+ | ; if not (GetRegistryStringValue32(" | ||
+ | ; comment "MSI id " + $MsiId32$ + " found in registry, starting msiexec to uninstall" | ||
+ | ; | ||
+ | ; | ||
+ | ; endif | ||
+ | |||
comment " | comment " | ||
+ | Files_uninstall_32 /32Bit | ||
Files_uninstall_allusers / | Files_uninstall_allusers / | ||
+ | comment " | ||
+ | Registry_uninstall /32Bit | ||
endif | endif | ||
- | + | if ($INST_SystemType$ = "64 Bit System" | |
- | if ($INST_SystemType$ = "64 Bit System" | + | ;and (($INST_architecture$ = " |
- | Message " | + | Message " |
if FileExists($UninstallProgram64$) | if FileExists($UninstallProgram64$) | ||
comment " | comment " | ||
- | ExecWith_uninstall_64 " | + | Winbatch_uninstall_64 |
sub_check_exitcode | sub_check_exitcode | ||
endif | endif | ||
- | + | ||
+ | ; if not (GetRegistryStringValue64(" | ||
+ | ; comment "MSI id " + $MsiId64$ + " found in registry, starting msiexec to uninstall" | ||
+ | ; | ||
+ | ; | ||
+ | ; endif | ||
+ | |||
comment " | comment " | ||
+ | Files_uninstall_64 /64Bit | ||
Files_uninstall_allusers / | Files_uninstall_allusers / | ||
+ | comment " | ||
+ | Registry_uninstall /64Bit | ||
endif | endif | ||
+ | |||
+ | comment " | ||
+ | LinkFolder_uninstall | ||
[Winbatch_uninstall_32] | [Winbatch_uninstall_32] | ||
rundll32.exe advpack.dll, | rundll32.exe advpack.dll, | ||
- | [ExecWith_uninstall_64] | + | [Files_uninstall_32] |
+ | ; Example for recursively deleting the installation directory (don't forget the trailing backslash): | ||
+ | ; | ||
+ | ; delete -sf " | ||
+ | |||
+ | [Winbatch_uninstall_64] | ||
rundll32.exe advpack.dll, | rundll32.exe advpack.dll, | ||
+ | |||
+ | [Files_uninstall_64] | ||
+ | ; Example for recursively deleting the installation directory (don't forget the trailing backslash): | ||
+ | ; | ||
+ | ; delete -sf " | ||
+ | |||
[Files_uninstall_allusers] | [Files_uninstall_allusers] | ||
- | delete -f "%UserProfileDir%\Application Data\Notepad2.ini" | + | delete -f "%AppdataDir%\Notepad2.ini" |
+ | |||
+ | [Registry_uninstall] | ||
+ | ; Example of deleting a registry key: | ||
+ | ; | ||
+ | ; deletekey [HKEY_LOCAL_MACHINE\Software\$ProductId$] | ||
+ | |||
+ | [LinkFolder_uninstall] | ||
+ | ; Example of deleting a folder from AllUsers startmenu: | ||
+ | ; | ||
+ | ; set_basefolder common_programs | ||
+ | ; delete_subfolder $ProductId$ | ||
+ | ; | ||
+ | ; Example of deleting a shortcut from AllUsers desktop: | ||
+ | ; | ||
+ | ; set_basefolder common_desktopdirectory | ||
+ | ; set_subfolder "" | ||
+ | ; delete_element $ProductId$ | ||
[Sub_check_exitcode] | [Sub_check_exitcode] | ||
Line 266: | Line 523: | ||
endif | endif | ||
endif | endif | ||
- | |||
</ | </ |