From a299ec043bda9ab25bb9a08764fee2eafe61e2c4 Mon Sep 17 00:00:00 2001 From: Denys Konovalov Date: Sun, 15 Sep 2024 14:38:59 +0200 Subject: [PATCH] Various fixes for Windows version - new installer based on InnoSetup - add MIT license - produce WinExe output - other small fixes --- LICENSE | 21 ++++++++ Photomator.nsi | 74 ----------------------------- Photomator/AppInfo.cs | 2 +- Photomator/Photomator.csproj | 8 ++-- Photomator/Program.cs | 3 +- Photomator/Resources/Photomator.iss | 65 +++++++++++++++++++++++++ Photomator/Views/StatusDialog.cs | 21 ++------ 7 files changed, 97 insertions(+), 97 deletions(-) create mode 100644 LICENSE delete mode 100644 Photomator.nsi create mode 100644 Photomator/Resources/Photomator.iss diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..f5713ba --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2024 Denys Konovalov + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/Photomator.nsi b/Photomator.nsi deleted file mode 100644 index e3f6dce..0000000 --- a/Photomator.nsi +++ /dev/null @@ -1,74 +0,0 @@ -Unicode true - -!include "MUI2.nsh" -!include "x64.nsh" -!include "nsDialogs.nsh" -!include "FileFunc.nsh" - -Function .onInit - ${If} ${RunningX64} - # 64 bit code - SetRegView 64 - ${Else} - # 32 bit code - MessageBox MB_OK "Photomator unterstützt nur 64-Bit-Systeme." - Abort - ${EndIf} -FunctionEnd - -!define ARP "Software\Microsoft\Windows\CurrentVersion\Uninstall\Photomator" - -Name "Photomator" -OutFile "photomator-setup.exe" - -BrandingText "Copyright (c) 2024 Denys Konovalov" - -InstallDir "$PROGRAMFILES\GCG\Photomator" - -RequestExecutionLevel admin - -!insertmacro MUI_LANGUAGE "German" - -!define MUI_ABORTWARNING - -!insertmacro MUI_PAGE_DIRECTORY -!insertmacro MUI_PAGE_INSTFILES - -!insertmacro MUI_UNPAGE_CONFIRM -!insertmacro MUI_UNPAGE_INSTFILES - -Section "Install" - SetOutPath $INSTDIR - - File /nonfatal /a /r "Photomator\bin\Release\net8.0\win-x64\publish\" - - CreateShortcut "$SMPROGRAMS\Photomator.lnk" "$INSTDIR\bin\Photomator.exe" - - WriteUninstaller "$INSTDIR\Uninstall.exe" - - ${GetSize} "$INSTDIR" "/S=0K" $0 $1 $2 - IntFmt $0 "0x%08X" $0 - WriteRegDWORD HKLM "${ARP}" "EstimatedSize" "$0" - - WriteRegStr HKLM "${ARP}" "DisplayName" "Photomator" - WriteRegStr HKLM "${ARP}" "InstallLocation" "$\"$INSTDIR$\"" - WriteRegStr HKLM "${ARP}" "Publisher" "Georg-Cantor-Gymnasium Halle (Saale)" - WriteRegStr HKLM "${ARP}" "VersionMajor" "0" - WriteRegStr HKLM "${ARP}" "VersionMinor" "01" - WriteRegStr HKLM "${ARP}" "UninstallString" "$\"$INSTDIR\Uninstall.exe$\"" -SectionEnd - -Section "uninstall" - SetRegView 64 - - Delete "$SMPROGRAMS\Photomator.lnk" - - Delete "$INSTDIR\Uninstall.exe" - RMDir /R "$INSTDIR\bin\" - RMDir /R "$INSTDIR\lib\" - RMDir /R "$INSTDIR\share\" - - DeleteRegKey HKLM "${ARP}" - - RMDir /R $INSTDIR -SectionEnd \ No newline at end of file diff --git a/Photomator/AppInfo.cs b/Photomator/AppInfo.cs index 58c4f3c..c5cba0d 100644 --- a/Photomator/AppInfo.cs +++ b/Photomator/AppInfo.cs @@ -5,7 +5,7 @@ public static class AppInfo { public static readonly string IconName = "de.cantorgymnasium.Photomator"; public static readonly string Version = ThisAssembly.Git.Tag; public static readonly string ReleaseNotes = @" -

0.0.1

+

v0.0.1

Initial release