diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 9fb775e24f..0247cc9673 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -3,9 +3,6 @@ name: Build Cemu on: workflow_call: inputs: - deploymode: - required: false - type: string experimentalversion: required: false type: string @@ -24,20 +21,12 @@ jobs: submodules: "recursive" fetch-depth: 0 - - name: Setup release mode parameters (for deploy) - if: ${{ inputs.deploymode == 'release' }} + - name: Setup release mode parameters run: | echo "BUILD_MODE=release" >> $GITHUB_ENV echo "BUILD_FLAGS=" >> $GITHUB_ENV echo "Build mode is release" - - name: Setup debug mode parameters (for continous build) - if: ${{ inputs.deploymode != 'release' }} - run: | - echo "BUILD_MODE=debug" >> $GITHUB_ENV - echo "BUILD_FLAGS=" >> $GITHUB_ENV - echo "Build mode is debug" - - name: Setup version for experimental if: ${{ inputs.experimentalversion != '' }} run: | @@ -81,12 +70,10 @@ jobs: cmake --build build - name: Prepare artifact - if: ${{ inputs.deploymode == 'release' }} run: mv bin/Cemu_release bin/Cemu - name: Upload artifact uses: actions/upload-artifact@v4 - if: ${{ inputs.deploymode == 'release' }} with: name: cemu-bin-linux-x64 path: ./bin/Cemu @@ -128,19 +115,12 @@ jobs: with: submodules: "recursive" - - name: Setup release mode parameters (for deploy) - if: ${{ inputs.deploymode == 'release' }} + - name: Setup release mode parameters run: | echo "BUILD_MODE=release" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf8 -Append echo "BUILD_FLAGS=" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf8 -Append echo "Build mode is release" - - - name: Setup debug mode parameters (for continous build) - if: ${{ inputs.deploymode != 'release' }} - run: | - echo "BUILD_MODE=debug" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf8 -Append - echo "BUILD_FLAGS=" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf8 -Append - echo "Build mode is debug" + - name: Setup version for experimental if: ${{ inputs.experimentalversion != '' }} run: | @@ -184,12 +164,10 @@ jobs: cmake --build . --config ${{ env.BUILD_MODE }} - name: Prepare artifact - if: ${{ inputs.deploymode == 'release' }} run: Rename-Item bin/Cemu_release.exe Cemu.exe - name: Upload artifact uses: actions/upload-artifact@v4 - if: ${{ inputs.deploymode == 'release' }} with: name: cemu-bin-windows-x64 path: ./bin/Cemu.exe @@ -202,19 +180,12 @@ jobs: with: submodules: "recursive" - - name: Setup release mode parameters (for deploy) - if: ${{ inputs.deploymode == 'release' }} + - name: Setup release mode parameters run: | echo "BUILD_MODE=release" >> $GITHUB_ENV echo "BUILD_FLAGS=" >> $GITHUB_ENV echo "Build mode is release" - - name: Setup debug mode parameters (for continous build) - if: ${{ inputs.deploymode != 'release' }} - run: | - echo "BUILD_MODE=debug" >> $GITHUB_ENV - echo "BUILD_FLAGS=" >> $GITHUB_ENV - echo "Build mode is debug" - + - name: Setup version for experimental if: ${{ inputs.experimentalversion != '' }} run: | @@ -275,7 +246,6 @@ jobs: cmake --build build - name: Prepare artifact - if: ${{ inputs.deploymode == 'release' }} run: | mkdir bin/Cemu_app mv bin/Cemu_release.app bin/Cemu_app/Cemu.app @@ -289,7 +259,6 @@ jobs: - name: Upload artifact uses: actions/upload-artifact@v4 - if: ${{ inputs.deploymode == 'release' }} with: name: cemu-bin-macos-x64 path: ./bin/Cemu.dmg diff --git a/.github/workflows/build_check.yml b/.github/workflows/build_check.yml index 49ef79e9ff..d60e0ecf3e 100644 --- a/.github/workflows/build_check.yml +++ b/.github/workflows/build_check.yml @@ -17,5 +17,4 @@ jobs: build: uses: ./.github/workflows/build.yml with: - deploymode: release experimentalversion: 999999 diff --git a/.github/workflows/deploy_experimental_release.yml b/.github/workflows/deploy_experimental_release.yml index a8c5ec53dc..78bc162e8f 100644 --- a/.github/workflows/deploy_experimental_release.yml +++ b/.github/workflows/deploy_experimental_release.yml @@ -1,20 +1,35 @@ name: Deploy experimental release on: workflow_dispatch: + inputs: + changelog: + description: 'Enter the changelog for this release' + required: true + type: string + changelog0: + required: false + type: string jobs: call-release-build: uses: ./.github/workflows/build.yml with: - deploymode: release experimentalversion: ${{ github.run_number }} deploy: name: Deploy experimental release runs-on: ubuntu-22.04 needs: call-release-build steps: - - uses: actions/checkout@v3 - + - uses: actions/checkout@v4 + with: + fetch-depth: 0 + + - name: Use GitVersion to generate version + id: gitversion + uses: gittools/actions/gitversion/setup@v3.0.0 + with: + versionSpec: '2.x' + - uses: actions/download-artifact@v4 with: name: cemu-bin-linux-x64 @@ -40,6 +55,13 @@ jobs: mkdir upload sudo apt install zip + - name: Get version (via gitversion) + run: | + echo "Version from GitVersion: ${{ steps.gitversion.outputs.fullsemver }}" + echo "Version from GitVersion (Major.Minor): ${{ steps.gitversion.outputs.Major }}.${{ steps.gitversion.outputs.Minor }}" + echo "CEMU_FOLDER_NAME=Cemu_${{ steps.gitversion.outputs.fullsemver }}" >> $GITHUB_ENV + echo "CEMU_VERSION=${{ steps.gitversion.outputs.fullsemver }}" >> $GITHUB_ENV + - name: Get version run: | echo "Experimental version: ${{ github.run_number }}" @@ -83,4 +105,10 @@ jobs: wget -O ghr.tar.gz https://github.com/tcnksm/ghr/releases/download/v0.15.0/ghr_v0.15.0_linux_amd64.tar.gz tar xvzf ghr.tar.gz; rm ghr.tar.gz echo "[INFO] Release tag: v${{ env.CEMU_VERSION }}" - ghr_v0.15.0_linux_amd64/ghr -prerelease -t ${{ secrets.GITHUB_TOKEN }} -n "Cemu ${{ env.CEMU_VERSION }} (Experimental)" -b "Cemu experimental release" "v${{ env.CEMU_VERSION }}" ./upload + RELEASE_BODY=$(printf "%s\n%s\n\n%s\n\n%s\n%s" \ + "Cemu ${{ env.CEMU_VERSION }} (Experimental)" \ + "" \ + "This is an experimental release." \ + "" \ + "${{ github.event.inputs.changelog }}") + ghr_v0.15.0_linux_amd64/ghr -prerelease -t ${{ secrets.GITHUB_TOKEN }} -n "Cemu ${{ env.CEMU_VERSION }} (Experimental)" -b "$RELEASE_BODY" "v${{ env.CEMU_VERSION }}" ./upload diff --git a/src/gui/GeneralSettings2.cpp b/src/gui/GeneralSettings2.cpp index 08395cd313..a5c18fabd9 100644 --- a/src/gui/GeneralSettings2.cpp +++ b/src/gui/GeneralSettings2.cpp @@ -162,19 +162,25 @@ wxPanel* GeneralSettings2::AddGeneralPage(wxNotebook* notebook) m_fullscreen_menubar->SetToolTip(_("Displays the menu bar when Cemu is running in fullscreen mode and the mouse cursor is moved to the top")); second_row->Add(m_fullscreen_menubar, 0, botflag, 5); + m_auto_update = new wxCheckBox(box, wxID_ANY, _("Automatically check for updates")); m_auto_update->SetToolTip(_("Automatically checks for new cemu versions on startup")); second_row->Add(m_auto_update, 0, botflag, 5); + + second_row->AddSpacer(10); + m_cutting_edge_updates = new wxCheckBox(box, wxID_ANY, _("Update to cutting-edge")); + m_cutting_edge_updates->SetToolTip(_("Update to new and untested releases")); + second_row->Add(m_cutting_edge_updates, 0, botflag, 5); #if BOOST_OS_LINUX if (!std::getenv("APPIMAGE")) { m_auto_update->Disable(); } #endif - second_row->AddSpacer(10); m_save_screenshot = new wxCheckBox(box, wxID_ANY, _("Save screenshot")); m_save_screenshot->SetToolTip(_("Pressing the screenshot key (F12) will save a screenshot directly to the screenshots folder")); second_row->Add(m_save_screenshot, 0, botflag, 5); + second_row->AddSpacer(10); m_disable_screensaver = new wxCheckBox(box, wxID_ANY, _("Disable screen saver")); m_disable_screensaver->SetToolTip(_("Prevents the system from activating the screen saver or going to sleep while running a game.")); second_row->Add(m_disable_screensaver, 0, botflag, 5); diff --git a/src/gui/GeneralSettings2.h b/src/gui/GeneralSettings2.h index a3429fa1c8..57717c8724 100644 --- a/src/gui/GeneralSettings2.h +++ b/src/gui/GeneralSettings2.h @@ -41,7 +41,7 @@ class GeneralSettings2 : public wxDialog wxCheckBox* m_save_window_position_size; wxCheckBox* m_save_padwindow_position_size; wxCheckBox* m_discord_presence, *m_fullscreen_menubar; - wxCheckBox* m_auto_update, *m_save_screenshot; + wxCheckBox* m_auto_update, *m_cutting_edge_updates, *m_save_screenshot; wxCheckBox* m_disable_screensaver; #if BOOST_OS_LINUX && defined(ENABLE_FERAL_GAMEMODE) wxCheckBox* m_feral_gamemode;