From dc799cf87ba8777bcdddc62b914fb9fb33a80bf8 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 6 Apr 2025 00:27:19 +0000 Subject: [PATCH 01/10] chore(nix): update lockfile MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Flake lock file updates: • Updated input 'nixpkgs': 'github:NixOS/nixpkgs/5e5402ecbcb27af32284d4a62553c019a3a49ea6?narHash=sha256-gWd4urRoLRe8GLVC/3rYRae1h%2BxfQzt09xOfb0PaHSk%3D' (2025-03-27) → 'github:NixOS/nixpkgs/2c8d3f48d33929642c1c12cd243df4cc7d2ce434?narHash=sha256-F7n4%2BKOIfWrwoQjXrL2wD9RhFYLs2/GGe/MQY1sSdlE%3D' (2025-04-02) (cherry picked from commit aec410cb28bb844f3e3bc0e1a2040a90baf09b71) --- flake.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/flake.lock b/flake.lock index d8c7c5248..996d79e22 100644 --- a/flake.lock +++ b/flake.lock @@ -18,11 +18,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1743095683, - "narHash": "sha256-gWd4urRoLRe8GLVC/3rYRae1h+xfQzt09xOfb0PaHSk=", + "lastModified": 1743583204, + "narHash": "sha256-F7n4+KOIfWrwoQjXrL2wD9RhFYLs2/GGe/MQY1sSdlE=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "5e5402ecbcb27af32284d4a62553c019a3a49ea6", + "rev": "2c8d3f48d33929642c1c12cd243df4cc7d2ce434", "type": "github" }, "original": { From 8fe7975ab8d813f124914c3e83814379a0c4474d Mon Sep 17 00:00:00 2001 From: Seth Flynn Date: Mon, 7 Apr 2025 09:07:02 -0400 Subject: [PATCH 02/10] revert: downgrade macos builds to qt 6.7.3 Fixes: https://github.com/PrismLauncher/PrismLauncher/issues/3592 Refs: https://github.com/PrismLauncher/PrismLauncher/pull/2895 Signed-off-by: Seth Flynn --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 5476ac431..fd74aa246 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -106,7 +106,7 @@ jobs: qt_ver: 6 qt_host: mac qt_arch: "" - qt_version: "6.8.1" + qt_version: "6.7.3" qt_modules: "qt5compat qtimageformats qtnetworkauth" - os: macos-14 From be2d144b4066430bf7d84c03663ff93d57b84238 Mon Sep 17 00:00:00 2001 From: Seth Flynn Date: Sun, 6 Apr 2025 17:08:25 -0400 Subject: [PATCH 03/10] ci: use ninja with msvc on x64 Signed-off-by: Seth Flynn (cherry picked from commit d92f7b3c9710679550111037fb7e41fe64443927) --- .github/workflows/build.yml | 37 ++++++++++++++++++++++--------------- 1 file changed, 22 insertions(+), 15 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 5476ac431..9ba99f861 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -171,6 +171,12 @@ jobs: with: key: ${{ matrix.os }}-qt${{ matrix.qt_ver }}-${{ matrix.architecture }} + - name: Use ccache on Debug builds only + if: inputs.build_type == 'Debug' + shell: bash + run: | + echo "CCACHE_VAR=ccache" >> $GITHUB_ENV + - name: Retrieve ccache cache (Windows MinGW-w64) if: runner.os == 'Windows' && matrix.msystem != '' && inputs.build_type == 'Debug' uses: actions/cache@v4.2.0 @@ -190,11 +196,17 @@ jobs: ccache -p # Show config ccache -z # Zero stats - - name: Use ccache on Debug builds only - if: inputs.build_type == 'Debug' - shell: bash + - name: Configure ccache (Windows MSVC) + if: ${{ runner.os == 'Windows' && matrix.msystem == '' && inputs.build_type == 'Debug' }} run: | - echo "CCACHE_VAR=ccache" >> $GITHUB_ENV + # https://github.com/ccache/ccache/wiki/MS-Visual-Studio (I coudn't figure out the compiler prefix) + Copy-Item C:/ProgramData/chocolatey/lib/ccache/tools/ccache-4.7.1-windows-x86_64/ccache.exe -Destination C:/ProgramData/chocolatey/lib/ccache/tools/ccache-4.7.1-windows-x86_64/cl.exe + echo "CLToolExe=cl.exe" >> $env:GITHUB_ENV + echo "CLToolPath=C:/ProgramData/chocolatey/lib/ccache/tools/ccache-4.7.1-windows-x86_64/" >> $env:GITHUB_ENV + echo "TrackFileAccess=false" >> $env:GITHUB_ENV + # Needed for ccache, but also speeds up compile + echo "UseMultiToolTask=true" >> $env:GITHUB_ENV + - name: Set short version shell: bash @@ -300,19 +312,14 @@ jobs: cmake -S . -B ${{ env.BUILD_DIR }} -DCMAKE_INSTALL_PREFIX=${{ env.INSTALL_DIR }} -DCMAKE_BUILD_TYPE=${{ inputs.build_type }} -DENABLE_LTO=ON -DLauncher_ENABLE_JAVA_DOWNLOADER=ON -DLauncher_BUILD_PLATFORM=official -DCMAKE_C_COMPILER_LAUNCHER=${{ env.CCACHE_VAR }} -DCMAKE_CXX_COMPILER_LAUNCHER=${{ env.CCACHE_VAR }} -DLauncher_QT_VERSION_MAJOR=6 -DCMAKE_OBJDUMP=/mingw64/bin/objdump.exe -DLauncher_BUILD_ARTIFACT=${{ matrix.name }}-Qt${{ matrix.qt_ver }} -G Ninja - name: Configure CMake (Windows MSVC) - if: runner.os == 'Windows' && matrix.msystem == '' + if: runner.os == 'Windows' && matrix.msystem == '' && matrix.architecture != 'arm64' + run: | + cmake -S . -B ${{ env.BUILD_DIR }} -DCMAKE_INSTALL_PREFIX=${{ env.INSTALL_DIR }} -DCMAKE_BUILD_TYPE=${{ inputs.build_type }} -DENABLE_LTO=ON -DLauncher_ENABLE_JAVA_DOWNLOADER=ON -DLauncher_BUILD_PLATFORM=official -DLauncher_QT_VERSION_MAJOR=${{ matrix.qt_ver }} -DCMAKE_MSVC_RUNTIME_LIBRARY="MultiThreadedDLL" -DLauncher_FORCE_BUNDLED_LIBS=ON -DLauncher_BUILD_ARTIFACT=${{ matrix.name }}-Qt${{ matrix.qt_ver }} -G Ninja + + - name: Configure CMake (Windows MSVC arm64) + if: runner.os == 'Windows' && matrix.msystem == '' && matrix.architecture == 'arm64' run: | cmake -S . -B ${{ env.BUILD_DIR }} -DCMAKE_INSTALL_PREFIX=${{ env.INSTALL_DIR }} -DCMAKE_BUILD_TYPE=${{ inputs.build_type }} -DENABLE_LTO=ON -DLauncher_ENABLE_JAVA_DOWNLOADER=ON -DLauncher_BUILD_PLATFORM=official -DLauncher_QT_VERSION_MAJOR=${{ matrix.qt_ver }} -DCMAKE_MSVC_RUNTIME_LIBRARY="MultiThreadedDLL" -A${{ matrix.architecture}} -DLauncher_FORCE_BUNDLED_LIBS=ON -DLauncher_BUILD_ARTIFACT=${{ matrix.name }}-Qt${{ matrix.qt_ver }} - # https://github.com/ccache/ccache/wiki/MS-Visual-Studio (I coudn't figure out the compiler prefix) - if ("${{ env.CCACHE_VAR }}") - { - Copy-Item C:/ProgramData/chocolatey/lib/ccache/tools/ccache-4.7.1-windows-x86_64/ccache.exe -Destination C:/ProgramData/chocolatey/lib/ccache/tools/ccache-4.7.1-windows-x86_64/cl.exe - echo "CLToolExe=cl.exe" >> $env:GITHUB_ENV - echo "CLToolPath=C:/ProgramData/chocolatey/lib/ccache/tools/ccache-4.7.1-windows-x86_64/" >> $env:GITHUB_ENV - echo "TrackFileAccess=false" >> $env:GITHUB_ENV - } - # Needed for ccache, but also speeds up compile - echo "UseMultiToolTask=true" >> $env:GITHUB_ENV - name: Configure CMake (Linux) if: runner.os == 'Linux' From feefeecea976625f4c467230cbbd68edfb1d4c7d Mon Sep 17 00:00:00 2001 From: Seth Flynn Date: Mon, 7 Apr 2025 08:11:59 -0400 Subject: [PATCH 04/10] ci(nix): run on tags Signed-off-by: Seth Flynn (cherry picked from commit da3a4984909b4b1d801018bf80eb93feadc97100) --- .github/workflows/nix.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/nix.yml b/.github/workflows/nix.yml index 0792b172c..9c809f37b 100644 --- a/.github/workflows/nix.yml +++ b/.github/workflows/nix.yml @@ -2,6 +2,8 @@ name: Nix on: push: + tags: + - "*" paths-ignore: - "**.md" - "**/LICENSE" From 1e201beb41916187ace29a1bd2ee1632b889f6b0 Mon Sep 17 00:00:00 2001 From: Seth Flynn Date: Mon, 7 Apr 2025 08:11:59 -0400 Subject: [PATCH 05/10] ci(nix): ignore more paths Signed-off-by: Seth Flynn (cherry picked from commit 1a5a162727c7d9d91aefd3852c127d60179844ae) --- .github/workflows/nix.yml | 27 +++++++++++++++++---------- 1 file changed, 17 insertions(+), 10 deletions(-) diff --git a/.github/workflows/nix.yml b/.github/workflows/nix.yml index 9c809f37b..f5f39b191 100644 --- a/.github/workflows/nix.yml +++ b/.github/workflows/nix.yml @@ -5,20 +5,27 @@ on: tags: - "*" paths-ignore: + - ".github/**" + - "!.github/workflows/nix.yml" + - "flatpak/" + - "scripts/" + + - ".git*" + - ".envrc" - "**.md" - - "**/LICENSE" - - ".github/ISSUE_TEMPLATE/**" - - ".markdownlint**" - - "flatpak/**" - tags: - - "*" + - "!COPYING.md" + - "renovate.json" pull_request_target: paths-ignore: + - ".github/**" + - "flatpak/" + - "scripts/" + + - ".git*" + - ".envrc" - "**.md" - - "**/LICENSE" - - ".github/ISSUE_TEMPLATE/**" - - ".markdownlint**" - - "flatpak/**" + - "!COPYING.md" + - "renovate.json" workflow_dispatch: permissions: From 71dc114a09bc59929419fe67aa0fb1bf19b7005f Mon Sep 17 00:00:00 2001 From: Seth Flynn Date: Mon, 7 Apr 2025 08:19:58 -0400 Subject: [PATCH 06/10] ci(nix): correctly parse action env vars as bools Signed-off-by: Seth Flynn (cherry picked from commit 76bec385d6803e94899028695226d872185b3d39) --- .github/workflows/nix.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/nix.yml b/.github/workflows/nix.yml index f5f39b191..7d0514608 100644 --- a/.github/workflows/nix.yml +++ b/.github/workflows/nix.yml @@ -71,7 +71,7 @@ jobs: # For PRs - name: Setup Nix Magic Cache - if: ${{ env.USE_DETERMINATE }} + if: ${{ env.USE_DETERMINATE == 'true' }} uses: DeterminateSystems/flakehub-cache-action@v1 # For in-tree builds @@ -87,11 +87,11 @@ jobs: nix flake check --print-build-logs --show-trace - name: Build debug package - if: ${{ env.DEBUG }} + if: ${{ env.DEBUG == 'true' }} run: | nix build --print-build-logs .#prismlauncher-debug - name: Build release package - if: ${{ !env.DEBUG }} + if: ${{ env.DEBUG == 'false' }} run: | nix build --print-build-logs .#prismlauncher From f7dbdb79be8b50cf76d8e25dd4746e60c1015ed9 Mon Sep 17 00:00:00 2001 From: Seth Flynn Date: Mon, 7 Apr 2025 08:19:58 -0400 Subject: [PATCH 07/10] ci(nix): pin release packages in cachix Signed-off-by: Seth Flynn (cherry picked from commit 180292098d9c4ad87ed0d9babed92e152feb5475) --- .github/workflows/nix.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/nix.yml b/.github/workflows/nix.yml index 7d0514608..478b196ea 100644 --- a/.github/workflows/nix.yml +++ b/.github/workflows/nix.yml @@ -93,5 +93,11 @@ jobs: - name: Build release package if: ${{ env.DEBUG == 'false' }} + env: + TAG: ${{ github.ref_name }} + SYSTEM: ${{ matrix.system }} run: | nix build --print-build-logs .#prismlauncher + nix build --no-link --print-out-paths .#prismlauncher \ + | tee -a "$GITHUB_STEP_SUMMARY" \ + | xargs cachix pin prismlauncher "$TAG"-"$SYSTEM" From 879495942a382b2a68ea112fd992f4fbad796e16 Mon Sep 17 00:00:00 2001 From: Seth Flynn Date: Mon, 7 Apr 2025 08:32:30 -0400 Subject: [PATCH 08/10] revert: "feat: publish on flakehub" Flakehub requires semver. We don't use that (yet) Refs: 86cc6d3 Signed-off-by: Seth Flynn (cherry picked from commit 6386d044e3fc5ec056479e508ade4da993a81cd4) --- .github/workflows/publish.yml | 22 ---------------------- 1 file changed, 22 deletions(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index d49eb4b8d..8a7da812e 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -8,28 +8,6 @@ permissions: contents: read jobs: - flakehub: - name: FlakeHub - - runs-on: ubuntu-latest - - permissions: - id-token: write - - steps: - - name: Checkout repository - uses: actions/checkout@v4 - with: - ref: ${{ github.ref }} - - - name: Install Nix - uses: cachix/install-nix-action@v30 - - - name: Publish on FlakeHub - uses: determinatesystems/flakehub-push@v5 - with: - visibility: "public" - winget: name: Winget From 5598b6b12eadcaf208b57ae369e435ed770ffebf Mon Sep 17 00:00:00 2001 From: Seth Flynn Date: Mon, 7 Apr 2025 10:45:31 -0400 Subject: [PATCH 09/10] chore: bump to 9.4 Signed-off-by: Seth Flynn --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 3753ccab3..808c7d8cd 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -188,7 +188,7 @@ set(Launcher_FMLLIBS_BASE_URL "https://files.prismlauncher.org/fmllibs/" CACHE S ######## Set version numbers ######## set(Launcher_VERSION_MAJOR 9) -set(Launcher_VERSION_MINOR 3) +set(Launcher_VERSION_MINOR 4) set(Launcher_VERSION_NAME "${Launcher_VERSION_MAJOR}.${Launcher_VERSION_MINOR}") set(Launcher_VERSION_NAME4 "${Launcher_VERSION_MAJOR}.${Launcher_VERSION_MINOR}.0.0") From 39a70214197e493ad96954a54111c90e78c56494 Mon Sep 17 00:00:00 2001 From: Seth Flynn Date: Mon, 7 Apr 2025 11:48:54 -0400 Subject: [PATCH 10/10] revert: "ci: use ninja with msvc on x64" Ninja doesn't work in release mode. We need that Refs: be2d144 Signed-off-by: Seth Flynn --- .github/workflows/build.yml | 37 +++++++++++++++---------------------- 1 file changed, 15 insertions(+), 22 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 4a8b9283e..fd74aa246 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -171,12 +171,6 @@ jobs: with: key: ${{ matrix.os }}-qt${{ matrix.qt_ver }}-${{ matrix.architecture }} - - name: Use ccache on Debug builds only - if: inputs.build_type == 'Debug' - shell: bash - run: | - echo "CCACHE_VAR=ccache" >> $GITHUB_ENV - - name: Retrieve ccache cache (Windows MinGW-w64) if: runner.os == 'Windows' && matrix.msystem != '' && inputs.build_type == 'Debug' uses: actions/cache@v4.2.0 @@ -196,17 +190,11 @@ jobs: ccache -p # Show config ccache -z # Zero stats - - name: Configure ccache (Windows MSVC) - if: ${{ runner.os == 'Windows' && matrix.msystem == '' && inputs.build_type == 'Debug' }} + - name: Use ccache on Debug builds only + if: inputs.build_type == 'Debug' + shell: bash run: | - # https://github.com/ccache/ccache/wiki/MS-Visual-Studio (I coudn't figure out the compiler prefix) - Copy-Item C:/ProgramData/chocolatey/lib/ccache/tools/ccache-4.7.1-windows-x86_64/ccache.exe -Destination C:/ProgramData/chocolatey/lib/ccache/tools/ccache-4.7.1-windows-x86_64/cl.exe - echo "CLToolExe=cl.exe" >> $env:GITHUB_ENV - echo "CLToolPath=C:/ProgramData/chocolatey/lib/ccache/tools/ccache-4.7.1-windows-x86_64/" >> $env:GITHUB_ENV - echo "TrackFileAccess=false" >> $env:GITHUB_ENV - # Needed for ccache, but also speeds up compile - echo "UseMultiToolTask=true" >> $env:GITHUB_ENV - + echo "CCACHE_VAR=ccache" >> $GITHUB_ENV - name: Set short version shell: bash @@ -312,14 +300,19 @@ jobs: cmake -S . -B ${{ env.BUILD_DIR }} -DCMAKE_INSTALL_PREFIX=${{ env.INSTALL_DIR }} -DCMAKE_BUILD_TYPE=${{ inputs.build_type }} -DENABLE_LTO=ON -DLauncher_ENABLE_JAVA_DOWNLOADER=ON -DLauncher_BUILD_PLATFORM=official -DCMAKE_C_COMPILER_LAUNCHER=${{ env.CCACHE_VAR }} -DCMAKE_CXX_COMPILER_LAUNCHER=${{ env.CCACHE_VAR }} -DLauncher_QT_VERSION_MAJOR=6 -DCMAKE_OBJDUMP=/mingw64/bin/objdump.exe -DLauncher_BUILD_ARTIFACT=${{ matrix.name }}-Qt${{ matrix.qt_ver }} -G Ninja - name: Configure CMake (Windows MSVC) - if: runner.os == 'Windows' && matrix.msystem == '' && matrix.architecture != 'arm64' - run: | - cmake -S . -B ${{ env.BUILD_DIR }} -DCMAKE_INSTALL_PREFIX=${{ env.INSTALL_DIR }} -DCMAKE_BUILD_TYPE=${{ inputs.build_type }} -DENABLE_LTO=ON -DLauncher_ENABLE_JAVA_DOWNLOADER=ON -DLauncher_BUILD_PLATFORM=official -DLauncher_QT_VERSION_MAJOR=${{ matrix.qt_ver }} -DCMAKE_MSVC_RUNTIME_LIBRARY="MultiThreadedDLL" -DLauncher_FORCE_BUNDLED_LIBS=ON -DLauncher_BUILD_ARTIFACT=${{ matrix.name }}-Qt${{ matrix.qt_ver }} -G Ninja - - - name: Configure CMake (Windows MSVC arm64) - if: runner.os == 'Windows' && matrix.msystem == '' && matrix.architecture == 'arm64' + if: runner.os == 'Windows' && matrix.msystem == '' run: | cmake -S . -B ${{ env.BUILD_DIR }} -DCMAKE_INSTALL_PREFIX=${{ env.INSTALL_DIR }} -DCMAKE_BUILD_TYPE=${{ inputs.build_type }} -DENABLE_LTO=ON -DLauncher_ENABLE_JAVA_DOWNLOADER=ON -DLauncher_BUILD_PLATFORM=official -DLauncher_QT_VERSION_MAJOR=${{ matrix.qt_ver }} -DCMAKE_MSVC_RUNTIME_LIBRARY="MultiThreadedDLL" -A${{ matrix.architecture}} -DLauncher_FORCE_BUNDLED_LIBS=ON -DLauncher_BUILD_ARTIFACT=${{ matrix.name }}-Qt${{ matrix.qt_ver }} + # https://github.com/ccache/ccache/wiki/MS-Visual-Studio (I coudn't figure out the compiler prefix) + if ("${{ env.CCACHE_VAR }}") + { + Copy-Item C:/ProgramData/chocolatey/lib/ccache/tools/ccache-4.7.1-windows-x86_64/ccache.exe -Destination C:/ProgramData/chocolatey/lib/ccache/tools/ccache-4.7.1-windows-x86_64/cl.exe + echo "CLToolExe=cl.exe" >> $env:GITHUB_ENV + echo "CLToolPath=C:/ProgramData/chocolatey/lib/ccache/tools/ccache-4.7.1-windows-x86_64/" >> $env:GITHUB_ENV + echo "TrackFileAccess=false" >> $env:GITHUB_ENV + } + # Needed for ccache, but also speeds up compile + echo "UseMultiToolTask=true" >> $env:GITHUB_ENV - name: Configure CMake (Linux) if: runner.os == 'Linux'