diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index aa81e45..922e972 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -36,8 +36,14 @@ jobs: with: nuitka-version: main script-name: ytm2spt.py - enable-plugins: pyside6 - user-package-configuration-file: ytmusicapi.nuitka-package.config.yaml + # enable-plugins: pyside6 + # user-package-configuration-file: ytmusicapi.nuitka-package.config.yaml + + - name: Build Windows Installer + if: matrix.platform == 'windows-latest' + uses: Minionguyjpro/Inno-Setup-Action@v1.2.2 + with: + path: windows-installer.iss - id: runnerOS uses: ASzc/change-string-case-action@v6 @@ -70,7 +76,7 @@ jobs: - name: Zip Windows Executable run: | cd *windows-build - zip -9 ytm2spt-${{ github.ref_name }}-windows.zip *.exe + zip -9 ytm2spt-${{ github.ref_name }}-windows.zip *-installer.exe - name: Tar Linux Executable run: | diff --git a/windows-installer.iss b/windows-installer.iss new file mode 100644 index 0000000..3ba04dc --- /dev/null +++ b/windows-installer.iss @@ -0,0 +1,47 @@ +; Script generated by the Inno Setup Script Wizard. +; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES! + +#define MyAppName "ytm2spt" +#define MyAppVersion "1.0.0" +#define MyAppPublisher "Abhishek M J" +#define MyAppURL "https://github.com/abhishekmj303/ytm2spt" +#define MyAppExeName "ytm2spt.exe" + +[Setup] +; NOTE: The value of AppId uniquely identifies this application. Do not use the same AppId value in installers for other applications. +; (To generate a new GUID, click Tools | Generate GUID inside the IDE.) +AppId={{1D3251C7-B28D-4C1D-9477-6244D52CA08E} +AppName={#MyAppName} +AppVersion={#MyAppVersion} +;AppVerName={#MyAppName} {#MyAppVersion} +AppPublisher={#MyAppPublisher} +AppPublisherURL={#MyAppURL} +AppSupportURL={#MyAppURL} +AppUpdatesURL={#MyAppURL} +DefaultDirName={autopf}\{#MyAppName} +DisableProgramGroupPage=yes +; Remove the following line to run in administrative install mode (install for all users.) +PrivilegesRequired=lowest +PrivilegesRequiredOverridesAllowed=dialog +OutputDir=.\build +OutputBaseFilename=ytm2spt-installer +Compression=lzma +SolidCompression=yes +WizardStyle=modern + +[Languages] +Name: "english"; MessagesFile: "compiler:Default.isl" + +[Tasks] +Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked + +[Files] +Source: ".\build\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs createallsubdirs + +[Icons] +Name: "{autoprograms}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}" +Name: "{autodesktop}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; Tasks: desktopicon + +[Run] +Filename: "{app}\{#MyAppExeName}"; Description: "{cm:LaunchProgram,{#StringChange(MyAppName, '&', '&&')}}"; Flags: nowait postinstall skipifsilent + diff --git a/ytm2spt.py b/ytm2spt.py index c21218e..79c8b51 100644 --- a/ytm2spt.py +++ b/ytm2spt.py @@ -1,6 +1,12 @@ +# Nuitka Configuration +# nuitka-project: --enable-plugins=pyside6 +# nuitka-project: --user-package-configuration-file=ytmusicapi.nuitka-package.config.yaml +# # Compilation mode, standalone everywhere, except on macOS there app bundle -# nuitka-project-if: {OS} in ("Windows", "Linux", "FreeBSD"): +# nuitka-project-if: {OS} in ("Linux", "FreeBSD"): # nuitka-project: --onefile +# nuitka-project-if: {OS} == "Windows": +# nuitka-project: --standalone # nuitka-project-if: {OS} == "Darwin": # nuitka-project: --standalone # nuitka-project: --macos-create-app-bundle