]> asedeno.scripts.mit.edu Git - PuTTY.git/commitdiff
Update Inno Setup script. Tested with IS 5.0.8 on Win98SE; I think there are
authorJacob Nevins <jacobn@chiark.greenend.org.uk>
Tue, 1 Mar 2005 21:34:21 +0000 (21:34 +0000)
committerJacob Nevins <jacobn@chiark.greenend.org.uk>
Tue, 1 Mar 2005 21:34:21 +0000 (21:34 +0000)
a few things that will faze whatever we're using currently (2.0.19 or
thereabouts?), but nothing desperately modern. (NB, the 0.57 putty.iss works
fine with 5.0.8 and the installer is even 40k smaller.)

Notable changes:
 - Uninstallation now runs a variant of `putty -cleanup'. The variance is
   only in the text displayed; the user is still prompted, and the default
   action is (now) "keep" in both cases.
 - Optionally add an icon in the Quick Launch bar.
 - Make desktop item optionally for all users. (not tested)
 - "Create a Start Menu group" now handled via IS' own mechanism.

[originally from svn r5423]

CHECKLST.txt
windows/putty.iss
windows/window.c

index 61d37e1d3f23a1879d11649c22382b103ef9cf95..fb630701e3e1038750681531db15ade2b2086ee6 100644 (file)
@@ -64,7 +64,7 @@ orders them correctly with respect to releases):
 
  - putty/LATEST.VER
 
-The Windows installer script:
+The Windows installer script (_three_ times, on consecutive lines):
 
  - putty/windows/putty.iss
 
index 197eb170e282c16e6b51f22ce6e8eb45c1b056ae..e885221a36604c568fc204c7096dc076a6dd5798 100644 (file)
@@ -5,26 +5,32 @@
 ;\r
 ; TODO for future releases:\r
 ;\r
-;  - It would be neighbourly to set up an [UninstallRun] entry that ran\r
-;    some close cousin of `putty -cleanup', only it should prompt first\r
-;    in case the user wants to keep stuff. And make the `leave it alone'\r
-;    button the DEFAULT. And perhaps warn that on NT-style systems not\r
-;    everything will be caught by this.\r
+;  - It might be nice to have an option to add PSCP, Plink and PSFTP to\r
+;    the PATH. This is probably only practical on NT-class systems; I\r
+;    believe doing this on 9x would require mucking around with\r
+;    AUTOEXEC.BAT.\r
 ;\r
-;  - The Quick Launch bar is an interesting thought. Certainly a fair\r
-;    number of people actually _believe_ my silly joke about how PuTTY\r
-;    is the only thing that makes Windows usable, so perhaps they'd like\r
-;    that. Unchecked by default, though, I think.\r
-;     * does this need to be conditional on the Windows version?\r
+;  - Maybe a "custom" installation might be useful? Hassle with icons,\r
+;    though.\r
 \r
 [Setup]\r
 AppName=PuTTY\r
 AppVerName=PuTTY version 0.57\r
+VersionInfoTextVersion=Release 0.57\r
+AppVersion=0.57\r
+;FIXME -- enable this when we've got it going for individual EXEs too\r
+;         and are committed to the version numbering scheme.\r
+;VersionInfoVersion=0.57.0.0\r
+AppPublisher=Simon Tatham\r
+AppPublisherURL=http://www.chiark.greenend.org.uk/~sgtatham/putty/\r
+AppReadmeFile={app}\README.txt\r
 DefaultDirName={pf}\PuTTY\r
 DefaultGroupName=PuTTY\r
 UninstallDisplayIcon={app}\putty.exe\r
 ChangesAssociations=yes\r
+;ChangesEnvironment=yes -- when PATH munging is sorted (probably)\r
 Compression=zip/9\r
+AllowNoIcons=yes\r
 \r
 [Files]\r
 Source: "putty.exe"; DestDir: "{app}"\r
@@ -40,18 +46,23 @@ Source: "..\LICENCE"; DestDir: "{app}"
 Source: "..\README.txt"; DestDir: "{app}"; Flags: isreadme\r
 \r
 [Icons]\r
-Name: "{group}\PuTTY"; Filename: "{app}\putty.exe"; Tasks: startmenu\r
-Name: "{group}\PuTTY Manual"; Filename: "{app}\putty.hlp"; Tasks: startmenu\r
-Name: "{group}\PuTTY Web Site"; Filename: "{app}\website.url"; Tasks: startmenu\r
-Name: "{group}\PSFTP"; Filename: "{app}\psftp.exe"; Tasks: startmenu\r
-Name: "{group}\PuTTYgen"; Filename: "{app}\puttygen.exe"; Tasks: startmenu\r
-Name: "{group}\Pageant"; Filename: "{app}\pageant.exe"; Tasks: startmenu\r
-Name: "{userdesktop}\PuTTY"; Filename: "{app}\putty.exe"; Tasks: desktopicon\r
+Name: "{group}\PuTTY"; Filename: "{app}\putty.exe"; Comment: "SSH, Telnet and Rlogin client";\r
+Name: "{group}\PuTTY Manual"; Filename: "{app}\putty.hlp"\r
+Name: "{group}\PuTTY Web Site"; Filename: "{app}\website.url"\r
+Name: "{group}\PSFTP"; Filename: "{app}\psftp.exe"; Comment: "Command-line interactive SFTP client"\r
+Name: "{group}\PuTTYgen"; Filename: "{app}\puttygen.exe"; Comment: "PuTTY SSH key generation utility"\r
+Name: "{group}\Pageant"; Filename: "{app}\pageant.exe"; Comment: "PuTTY SSH authentication agent"\r
+Name: "{commondesktop}\PuTTY"; Filename: "{app}\putty.exe"; Tasks: desktopicon\common\r
+Name: "{userdesktop}\PuTTY"; Filename: "{app}\putty.exe"; Tasks: desktopicon\user\r
+; Putting this in {commonappdata} doesn't seem to work, on 98SE at least.\r
+Name: "{userappdata}\Microsoft\Internet Explorer\Quick Launch\PuTTY"; Filename: "{app}\putty.exe"; Tasks: quicklaunchicon\r
 \r
 [Tasks]\r
-Name: startmenu; Description: "Create a &Start Menu group"\r
-Name: desktopicon; Description: "Create a &desktop icon for PuTTY"\r
-Name: associate; Description: "&Associate .PPK files (PuTTY Private Key) with Pageant"\r
+Name: desktopicon; Description: "Create a &desktop icon for PuTTY"; GroupDescription: "Additional icons:"; Flags: unchecked\r
+Name: desktopicon\common; Description: "For all users"; GroupDescription: "Additional icons:"; Flags: exclusive unchecked\r
+Name: desktopicon\user; Description: "For the current user only"; GroupDescription: "Additional icons:"; Flags: exclusive unchecked\r
+Name: quicklaunchicon; Description: "Create a &Quick Launch icon for PuTTY (current user only)"; GroupDescription: "Additional icons:"; Flags: unchecked\r
+Name: associate; Description: "&Associate .PPK files (PuTTY Private Key) with Pageant and PuTTYgen"; GroupDescription: "Other tasks:"\r
 \r
 [Registry]\r
 Root: HKCR; Subkey: ".ppk"; ValueType: string; ValueName: ""; ValueData: "PuTTYPrivateKey"; Flags: uninsdeletevalue; Tasks: associate\r
@@ -60,3 +71,9 @@ Root: HKCR; Subkey: "PuTTYPrivateKey\DefaultIcon"; ValueType: string; ValueName:
 Root: HKCR; Subkey: "PuTTYPrivateKey\shell\open\command"; ValueType: string; ValueName: ""; ValueData: """{app}\pageant.exe"" ""%1"""; Tasks: associate\r
 Root: HKCR; Subkey: "PuTTYPrivateKey\shell\edit"; ValueType: string; ValueName: ""; ValueData: "&Edit"; Tasks: associate\r
 Root: HKCR; Subkey: "PuTTYPrivateKey\shell\edit\command"; ValueType: string; ValueName: ""; ValueData: """{app}\puttygen.exe"" ""%1"""; Tasks: associate\r
+; Add to PATH on NT-class OS?\r
+\r
+[UninstallRun]\r
+; -cleanup-during-uninstall is an undocumented option that tailors the\r
+; message displayed.\r
+Filename: "{app}\putty.exe"; Parameters: "-cleanup-during-uninstall"; RunOnceId: "PuTTYCleanup"; StatusMsg: "Cleaning up saved sessions etc (optional)..."\r
index 2105888786e6202dec162a4265009a5c9db1f3fd..40c69e54a46202ababf7503942f6e0a469af2018 100644 (file)
@@ -437,22 +437,41 @@ int WINAPI WinMain(HINSTANCE inst, HINSTANCE prev, LPSTR cmdline, int show)
                    i++;               /* skip next argument */
                } else if (ret == 1) {
                    continue;          /* nothing further needs doing */
-               } else if (!strcmp(p, "-cleanup")) {
+               } else if (!strcmp(p, "-cleanup") ||
+                          !strcmp(p, "-cleanup-during-uninstall")) {
                    /*
                     * `putty -cleanup'. Remove all registry
                     * entries associated with PuTTY, and also find
                     * and delete the random seed file.
                     */
                    char *s1, *s2;
-                   s1 = dupprintf("This procedure will remove ALL Registry\n"
-                                  "entries associated with %s, and will\n"
-                                  "also remove the random seed file.\n"
-                                  "\n"
-                                  "THIS PROCESS WILL DESTROY YOUR SAVED\n"
-                                  "SESSIONS. Are you really sure you want\n"
-                                  "to continue?", appname);
-                   s2 = dupprintf("%s Warning", appname);
-                   if (message_box(s1, s2, MB_YESNO | MB_ICONWARNING,
+                   /* Are we being invoked from an uninstaller? */
+                   if (!strcmp(p, "-cleanup-during-uninstall")) {
+                       s1 = dupprintf("Remove saved sessions and random seed file?\n"
+                                      "\n"
+                                      "If you hit Yes, ALL Registry entries associated\n"
+                                      "with %s will be removed, as well as the\n"
+                                      "random seed file. THIS PROCESS WILL\n"
+                                      "DESTROY YOUR SAVED SESSIONS.\n"
+                                      "(This only affects the currently logged-in user.)\n"
+                                      "\n"
+                                      "If you hit No, uninstallation will proceed, but\n"
+                                      "saved sessions etc will be left on the machine.",
+                                      appname);
+                       s2 = dupprintf("%s Uninstallation", appname);
+                   } else {
+                       s1 = dupprintf("This procedure will remove ALL Registry entries\n"
+                                      "associated with %s, and will also remove\n"
+                                      "the random seed file. (This only affects the\n"
+                                      "currently logged-in user.)\n"
+                                      "\n"
+                                      "THIS PROCESS WILL DESTROY YOUR SAVED SESSIONS.\n"
+                                      "Are you really sure you want to continue?",
+                                      appname);
+                       s2 = dupprintf("%s Warning", appname);
+                   }
+                   if (message_box(s1, s2,
+                                   MB_YESNO | MB_ICONWARNING | MB_DEFBUTTON2,
                                    HELPCTXID(option_cleanup)) == IDYES) {
                        cleanup_all();
                    }