mirror of
https://github.com/greenshot/greenshot
synced 2025-08-21 05:53:27 -07:00
Improvements for the installer
git-svn-id: http://svn.code.sf.net/p/greenshot/code/trunk@758 7dccd23d-a4a3-4e1f-8c07-b4c1b4018ab4
This commit is contained in:
parent
0a589956d7
commit
227f7a2ec9
1 changed files with 60 additions and 39 deletions
|
@ -1,3 +1,6 @@
|
||||||
|
#define ExeName "Greenshot"
|
||||||
|
#define Version "0.9.0.$WCREV$"
|
||||||
|
#define Mutex "F48E86D3-E34C-4DB7-8F8F-9A0EA55F0D08"
|
||||||
[Files]
|
[Files]
|
||||||
Source: ..\..\bin\Release\*; DestDir: {app}; Flags: overwritereadonly ignoreversion replacesameversion
|
Source: ..\..\bin\Release\*; DestDir: {app}; Flags: overwritereadonly ignoreversion replacesameversion
|
||||||
Source: ..\..\bin\Release\Languages\*; DestDir: {app}\Languages; Flags: overwritereadonly ignoreversion replacesameversion
|
Source: ..\..\bin\Release\Languages\*; DestDir: {app}\Languages; Flags: overwritereadonly ignoreversion replacesameversion
|
||||||
|
@ -6,36 +9,46 @@ Source: ..\additional_files\*; DestDir: {app}; Flags: overwritereadonly recurses
|
||||||
;Source: ..\..\bin\Release\Plugins\GreenshotFlickrPlugin\*; DestDir: {app}\Plugins\GreenshotFlickrPlugin; Components: plugins\flickr; Flags: overwritereadonly recursesubdirs ignoreversion replacesameversion;
|
;Source: ..\..\bin\Release\Plugins\GreenshotFlickrPlugin\*; DestDir: {app}\Plugins\GreenshotFlickrPlugin; Components: plugins\flickr; Flags: overwritereadonly recursesubdirs ignoreversion replacesameversion;
|
||||||
;Source: ..\..\bin\Release\Languages\Plugins\GreenshotFlickrPlugin\*; DestDir: {app}\Languages\Plugins\GreenshotFlickrPlugin; Components: plugins\flickr; Flags: overwritereadonly ignoreversion replacesameversion;
|
;Source: ..\..\bin\Release\Languages\Plugins\GreenshotFlickrPlugin\*; DestDir: {app}\Languages\Plugins\GreenshotFlickrPlugin; Components: plugins\flickr; Flags: overwritereadonly ignoreversion replacesameversion;
|
||||||
;OCR Plugin
|
;OCR Plugin
|
||||||
;Source: ..\..\bin\Release\Plugins\Greenshot-OCR-Plugin\*; DestDir: {app}\Plugins\Greenshot-OCR-Plugin; Components: plugins\ocr; Flags: overwritereadonly recursesubdirs ignoreversion replacesameversion;
|
Source: ..\..\bin\Release\Plugins\Greenshot-OCR-Plugin\*; DestDir: {app}\Plugins\Greenshot-OCR-Plugin; Components: plugins\ocr; Flags: overwritereadonly recursesubdirs ignoreversion replacesameversion;
|
||||||
;Source: ..\..\bin\Release\Languages\Plugins\Greenshot-OCR-Plugin\*; DestDir: {app}\Languages\Plugins\Greenshot-OCR-Plugin; Components: plugins\ocr; Flags: overwritereadonly ignoreversion replacesameversion;
|
Source: ..\..\bin\Release\Languages\Plugins\Greenshot-OCR-Plugin\*; DestDir: {app}\Languages\Plugins\Greenshot-OCR-Plugin; Components: plugins\ocr; Flags: overwritereadonly ignoreversion replacesameversion;
|
||||||
;JIRA Plugin
|
;JIRA Plugin
|
||||||
;Source: ..\..\bin\Release\Plugins\GreenshotJiraPlugin\*; DestDir: {app}\Plugins\GreenshotJiraPlugin; Components: plugins\jira; Flags: overwritereadonly recursesubdirs ignoreversion replacesameversion;
|
;Source: ..\..\bin\Release\Plugins\GreenshotJiraPlugin\*; DestDir: {app}\Plugins\GreenshotJiraPlugin; Components: plugins\jira; Flags: overwritereadonly recursesubdirs ignoreversion replacesameversion;
|
||||||
;Source: ..\..\bin\Release\Languages\Plugins\GreenshotJiraPlugin\*; DestDir: {app}\Languages\Plugins\GreenshotJiraPlugin; Components: plugins\jira; Flags: overwritereadonly ignoreversion replacesameversion;
|
;Source: ..\..\bin\Release\Languages\Plugins\GreenshotJiraPlugin\*; DestDir: {app}\Languages\Plugins\GreenshotJiraPlugin; Components: plugins\jira; Flags: overwritereadonly ignoreversion replacesameversion;
|
||||||
;Title-Fix Plugin
|
;Title-Fix Plugin
|
||||||
;Source: ..\..\bin\Release\Plugins\Greenshot-TitleFix-Plugin\*; DestDir: {app}\Plugins\Greenshot-TitleFix-Plugin; Components: plugins\titlefix; Flags: overwritereadonly recursesubdirs ignoreversion replacesameversion;
|
Source: ..\..\bin\Release\Plugins\Greenshot-TitleFix-Plugin\*; DestDir: {app}\Plugins\Greenshot-TitleFix-Plugin; Components: plugins\titlefix; Flags: overwritereadonly recursesubdirs ignoreversion replacesameversion;
|
||||||
;Source: ..\..\bin\Release\Languages\Plugins\Greenshot-TitleFix-Plugin\*; DestDir: {app}\Languages\Plugins\Greenshot-TitleFix-Plugin; Components: plugins\titlefix; Flags: overwritereadonly ignoreversion replacesameversion;
|
|
||||||
[Setup]
|
[Setup]
|
||||||
OutputDir=..\
|
OutputDir=..\
|
||||||
OutputBaseFilename=Greenshot-INSTALLER-0.9.0.$WCREV$
|
OutputBaseFilename={#ExeName}-INSTALLER-{#Version}
|
||||||
DefaultDirName={pf}\Greenshot
|
DefaultDirName={pf}\{#ExeName}
|
||||||
DefaultGroupName=Greenshot
|
DefaultGroupName={#ExeName}
|
||||||
AppName=Greenshot
|
AppId={#ExeName}
|
||||||
AppVerName=Greenshot 0.9.0.$WCREV$
|
AppName={#ExeName}
|
||||||
AppMutex=F48E86D3-E34C-4DB7-8F8F-9A0EA55F0D08,Global\F48E86D3-E34C-4DB7-8F8F-9A0EA55F0D08
|
AppPublisher={#ExeName}
|
||||||
|
AppPublisherURL=http://getgreenshot.org
|
||||||
|
AppSupportURL=http://getgreenshot.org
|
||||||
|
AppUpdatesURL=http://getgreenshot.org
|
||||||
|
AppVerName={#ExeName} {#Version}
|
||||||
|
AppVersion={#Version}
|
||||||
|
Compression=lzma/ultra64
|
||||||
|
InternalCompressLevel=ultra64
|
||||||
|
LanguageDetectionMethod=uilanguage
|
||||||
|
Uninstallable=true
|
||||||
|
UninstallDisplayIcon={app}\{#ExeName}.exe
|
||||||
|
VersionInfoCompany={#ExeName}
|
||||||
|
VersionInfoTextVersion={#Version}
|
||||||
|
VersionInfoVersion={#Version}
|
||||||
|
VersionInfoProductName={#ExeName}
|
||||||
PrivilegesRequired=admin
|
PrivilegesRequired=admin
|
||||||
; Reference a bitmap, max size 164x314
|
; Reference a bitmap, max size 164x314
|
||||||
WizardImageFile=installer-large.bmp
|
WizardImageFile=installer-large.bmp
|
||||||
; Reference a bitmap, max size 55x58
|
; Reference a bitmap, max size 55x58
|
||||||
WizardSmallImageFile=installer-small.bmp
|
WizardSmallImageFile=installer-small.bmp
|
||||||
VersionInfoVersion=0.9.0.$WCREV$
|
|
||||||
VersionInfoCompany=Greenshot
|
|
||||||
VersionInfoProductName=Greenshot
|
|
||||||
MinVersion=,5.01.2600
|
MinVersion=,5.01.2600
|
||||||
[Registry]
|
[Registry]
|
||||||
Root: HKCU; Subkey: Software\Microsoft\Windows\CurrentVersion\Run; ValueType: string; ValueName: Greenshot; ValueData: {app}\Greenshot.exe; Permissions: users-modify; Flags: uninsdeletevalue; Tasks: startup
|
Root: HKCU; Subkey: Software\Microsoft\Windows\CurrentVersion\Run; ValueType: string; ValueName: {#ExeName}; ValueData: {app}\{#ExeName}.exe; Permissions: users-modify; Flags: uninsdeletevalue; Tasks: startup
|
||||||
[Icons]
|
[Icons]
|
||||||
Name: {group}\Greenshot; Filename: {app}\Greenshot.exe; WorkingDir: {app}
|
Name: {group}\{#ExeName}; Filename: {app}\{#ExeName}.exe; WorkingDir: {app}
|
||||||
Name: {group}\Uninstall Greenshot; Filename: {app}\unins000.exe; WorkingDir: {app}
|
Name: {group}\Uninstall {#ExeName}; Filename: {app}\unins000.exe; WorkingDir: {app}
|
||||||
Name: {group}\Readme.txt; Filename: {app}\readme.txt; WorkingDir: {app}
|
Name: {group}\Readme.txt; Filename: {app}\readme.txt; WorkingDir: {app}
|
||||||
Name: {group}\License.txt; Filename: {app}\license.txt; WorkingDir: {app}
|
Name: {group}\License.txt; Filename: {app}\license.txt; WorkingDir: {app}
|
||||||
[Languages]
|
[Languages]
|
||||||
|
@ -44,33 +57,46 @@ Name: de; MessagesFile: compiler:Languages\German.isl
|
||||||
Name: nl; MessagesFile: compiler:Languages\Dutch.isl
|
Name: nl; MessagesFile: compiler:Languages\Dutch.isl
|
||||||
[Tasks]
|
[Tasks]
|
||||||
Name: startup; Description: {cm:startup}
|
Name: startup; Description: {cm:startup}
|
||||||
;[Components]
|
|
||||||
;Name: "plugins"; Description: "Plugins"; Types: Full
|
|
||||||
;Name: "plugins\ocr"; Description: "OCR Plugin"; Types: Full
|
|
||||||
;Name: "plugins\jira"; Description: "JIRA Plugin"; Types: Full
|
|
||||||
;Name: "plugins\titlefix"; Description: "Title-fix Plugin"; Types: Full
|
|
||||||
;Name: "plugins\flickr"; Description: "Flickr Plugin"; Types: Full
|
|
||||||
[CustomMessages]
|
[CustomMessages]
|
||||||
en.dotnetmissing=This setup requires the .NET Framework v2.0.%nDo you want to download the framework now?
|
en.dotnetmissing=This setup requires the .NET Framework v2.0.%nDo you want to download the framework now?
|
||||||
de.dotnetmissing=Dieses Programm benötigt Microsoft .NET Framework v2.0.%nWollen Sie das Framework jetzt downloaden?
|
de.dotnetmissing=Dieses Programm benötigt Microsoft .NET Framework v2.0.%nWollen Sie das Framework jetzt downloaden?
|
||||||
nl.dotnetmissing=Dit programma heeft Microsoft .NET Framework v2.0. nodig%nWilt u het Framework nu downloaden?
|
nl.dotnetmissing=Dit programma heeft Microsoft .NET Framework v2.0. nodig%nWilt u het Framework nu downloaden?
|
||||||
en.startup=Start Greenshot with Windows start
|
en.startup=Start {#ExeName} with Windows start
|
||||||
de.startup=Greenshot starten wenn Windows hochfahrt
|
de.startup={#ExeName} starten wenn Windows hochfahrt
|
||||||
nl.startup=Start Greenshot wanneer Windows opstart
|
nl.startup=Start {#ExeName} wanneer Windows opstart
|
||||||
en.startgreenshot=Start Greenshot
|
en.startgreenshot=Start {#ExeName}
|
||||||
de.startgreenshot=Greenshot starten
|
de.startgreenshot={#ExeName} starten
|
||||||
nl.startgreenshot=Start Greenshot
|
nl.startgreenshot=Start {#ExeName}
|
||||||
|
en.titlefix=Title cleanup for Internet explorer and Firefox
|
||||||
|
de.titlefix=Titel aufräumen bei Internet explorer und Firefox
|
||||||
|
nl.titlefix=Titel opruimen bij Internet explorer en Firefox
|
||||||
|
en.ocr=OCR Plugin (needs Microsoft Office 2003 or 2007)
|
||||||
|
de.ocr=OCR Plugin (braucht Microsoft Office 2003 oder 2007)
|
||||||
|
nl.ocr=OCR Plugin (heeft Microsoft Office 2003 of 2007 nodig)
|
||||||
|
[Components]
|
||||||
|
Name: "plugins"; Description: "Plugins"; Types: Full
|
||||||
|
Name: "plugins\ocr"; Description: {cm:ocr}; Types: Full
|
||||||
|
;Name: "plugins\jira"; Description: "JIRA Plugin"; Types: Full
|
||||||
|
Name: "plugins\titlefix"; Description: {cm:titlefix}; Types: Full
|
||||||
|
;Name: "plugins\flickr"; Description: "Flickr Plugin"; Types: Full
|
||||||
[Code]
|
[Code]
|
||||||
function InitializeSetup(): Boolean;
|
function InitializeSetup(): Boolean;
|
||||||
var
|
var
|
||||||
ErrorCode : Integer;
|
ErrorCode : Integer;
|
||||||
NetFrameWorkInstalled : Boolean;
|
NetFrameWorkInstalled : Boolean;
|
||||||
MsgBoxResult : Boolean;
|
MsgBoxResult : Boolean;
|
||||||
|
bMutex : Boolean;
|
||||||
|
resultCode: Integer;
|
||||||
begin
|
begin
|
||||||
|
|
||||||
NetFrameWorkInstalled := RegKeyExists(HKLM, 'SOFTWARE\Microsoft\.NETFramework\policy\v2.0');
|
NetFrameWorkInstalled := RegKeyExists(HKLM, 'SOFTWARE\Microsoft\.NETFramework\policy\v2.0');
|
||||||
if NetFrameWorkInstalled = true then
|
if NetFrameWorkInstalled = true then
|
||||||
begin
|
begin
|
||||||
|
bMutex:= CheckForMutexes ('Local\{#Mutex}');
|
||||||
|
if bMutex = True then
|
||||||
|
begin
|
||||||
|
Exec('taskkill.exe', '/F /IM Greenshot.exe', '', SW_HIDE, ewWaitUntilTerminated, ResultCode);
|
||||||
|
end;
|
||||||
Result := true;
|
Result := true;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
@ -80,10 +106,7 @@ begin
|
||||||
Result := false;
|
Result := false;
|
||||||
if MsgBoxResult = true then
|
if MsgBoxResult = true then
|
||||||
begin
|
begin
|
||||||
ShellExec(
|
ShellExec('open', 'http://download.microsoft.com/download/5/6/7/567758a3-759e-473e-bf8f-52154438565a/dotnetfx.exe', '','',SW_SHOWNORMAL,ewNoWait,ErrorCode);
|
||||||
'open', 'http://download.microsoft.com/download/5/6/7/567758a3-759e-473e-bf8f-52154438565a/dotnetfx.exe',
|
|
||||||
'','',SW_SHOWNORMAL,ewNoWait,ErrorCode
|
|
||||||
);
|
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
@ -93,18 +116,16 @@ var
|
||||||
bMutex : Boolean;
|
bMutex : Boolean;
|
||||||
resultCode: Integer;
|
resultCode: Integer;
|
||||||
begin
|
begin
|
||||||
bMutex:= CheckForMutexes ('Local\F48E86D3-E34C-4DB7-8F8F-9A0EA55F0D08');
|
bMutex:= CheckForMutexes ('Local\{#Mutex}');
|
||||||
if bMutex = True then
|
if bMutex = True then
|
||||||
begin
|
begin
|
||||||
Exec(ExpandConstant('{app}\greenshot.exe'), '--uninstall', '', SW_SHOW, ewWaitUntilTerminated, ResultCode);
|
Exec(ExpandConstant('{app}\{#ExeName}.exe'), '--uninstall', '', SW_HIDE, ewWaitUntilTerminated, ResultCode);
|
||||||
end;
|
end;
|
||||||
Result := True;
|
Result := True;
|
||||||
end;
|
end;
|
||||||
[Run]
|
[Run]
|
||||||
Filename: {app}\Greenshot.exe; Description: {cm:startgreenshot}; Parameters: --configure Ui_Language={language}; WorkingDir: {app}; Flags: nowait postinstall runasoriginaluser
|
Filename: {app}\{#ExeName}.exe; Description: {cm:startgreenshot}; Parameters: --configure Ui_Language={language}; WorkingDir: {app}; Flags: nowait postinstall runasoriginaluser
|
||||||
[UninstallRun]
|
|
||||||
Filename: {app}\Greenshot.exe; Parameters: --uninstall; WorkingDir: {app}; Languages:
|
|
||||||
[InstallDelete]
|
[InstallDelete]
|
||||||
Name: {app}; Type: filesandordirs; Languages:
|
Name: {app}; Type: filesandordirs; Languages:
|
||||||
Name: {userstartup}\Greenshot.lnk; Type: files; Languages:
|
Name: {userstartup}\{#ExeName}.lnk; Type: files; Languages:
|
||||||
Name: {commonstartup}\Greenshot.lnk; Type: files; Languages:
|
Name: {commonstartup}\{#ExeName}.lnk; Type: files; Languages:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue