diff --git a/.github/workflows/pull-request-create-release.yml b/.github/workflows/pull-request-create-release.yml index 9d80eb608..502210597 100644 --- a/.github/workflows/pull-request-create-release.yml +++ b/.github/workflows/pull-request-create-release.yml @@ -35,6 +35,9 @@ jobs: strategy: matrix: include: + - name: Linux + os: ubuntu-20.04 + dist_name: betty-linux - name: macOS os: macos-11 dist_name: betty-macos @@ -78,16 +81,33 @@ jobs: with: python-version: '3.12' + - name: Install APT dependencies + if: startsWith(runner.os, 'Linux') + run: | + sudo apt-get update + apt_packages=( + libegl1-mesa # For Qt + libx11-xcb-dev # For Qt + '^libxcb.*-dev' # For Qt + libxkbcommon-x11-0 # For Qt + ) + sudo apt-get install "${apt_packages[@]}" + - name: Build the executable run: ./bin/build-pyinstaller '${{ env.betty_tag }}-${{ github.event.pull_request.head.sha }}' shell: bash - - name: Zip the macOS executable + - name: Zip the Linux package + if: startsWith(runner.os, 'Linux') + run: zip -r -X './dist/${{ matrix.dist_name }}-${{ github.event.pull_request.head.sha }}.zip' './dist/betty' + shell: bash + + - name: Zip the macOS package if: startsWith(runner.os, 'macOS') - run: zip -X './dist/${{ matrix.dist_name }}-${{ github.event.pull_request.head.sha }}.zip' './dist/betty' + run: zip -r -X './dist/${{ matrix.dist_name }}-${{ github.event.pull_request.head.sha }}.zip' './dist/betty' shell: bash - - name: Zip the Windows executable + - name: Zip the Windows package if: startsWith(runner.os, 'Windows') run: Compress-Archive '.\dist\betty' '.\dist\${{ matrix.dist_name }}-${{ github.event.pull_request.head.sha }}.zip' @@ -109,7 +129,7 @@ jobs: shell: bash - name: Notify collaborators of the release - run: gh pr comment '${{ github.event.pull_request.number }}' --body $'Uploaded Betty for commit ${{ github.event.pull_request.head.sha }}. You can download it, test it, and post your feedback in a comment to this pull request 💕\n\n- [Betty Desktop for macOS 🍎](https://github.com/bartfeenstra/betty/releases/download/${{ env.betty_tag }}/betty-macos-${{ github.event.pull_request.head.sha }}.zip)\n- [Betty Desktop for Windows 🪟](https://github.com/bartfeenstra/betty/releases/download/${{ env.betty_tag }}/betty-windows-${{ github.event.pull_request.head.sha }}.zip)\n\nThe download will stop working when the pull request is closed.' + run: gh pr comment '${{ github.event.pull_request.number }}' --body $'Uploaded Betty for commit ${{ github.event.pull_request.head.sha }}. You can download it, test it, and post your feedback in a comment to this pull request 💕\n\n- [Betty Desktop for **Linux** 🐧](https://github.com/bartfeenstra/betty/releases/download/${{ env.betty_tag }}/betty-linux-${{ github.event.pull_request.head.sha }}.zip)\n- [Betty Desktop for **macOS** 🍎](https://github.com/bartfeenstra/betty/releases/download/${{ env.betty_tag }}/betty-macos-${{ github.event.pull_request.head.sha }}.zip)\n- [Betty Desktop for **Windows** 🪟](https://github.com/bartfeenstra/betty/releases/download/${{ env.betty_tag }}/betty-windows-${{ github.event.pull_request.head.sha }}.zip)\n\nThese downloads will stop working when the pull request is closed.' shell: bash env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/release-build-pyinstaller.yml b/.github/workflows/release-build-pyinstaller.yml index 78f9450f3..07db3f4a7 100644 --- a/.github/workflows/release-build-pyinstaller.yml +++ b/.github/workflows/release-build-pyinstaller.yml @@ -56,7 +56,7 @@ jobs: - name: Zip the macOS executable if: startsWith(runner.os, 'macOS') - run: zip -X ./dist/${{ matrix.dist_file_name }}.zip ./dist/${{ matrix.dist_file_name }} + run: zip -r -X ./dist/${{ matrix.dist_file_name }}.zip ./dist/${{ matrix.dist_file_name }} shell: bash - name: Zip the Windows executable diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 34467d572..e6d4c160a 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -98,8 +98,7 @@ jobs: sudo apt-get install "${apt_packages[@]}" - name: Build the development environment - run: | - ./bin/build-dev + run: ./bin/build-dev shell: bash - name: Get the Cypress cache directory @@ -118,14 +117,12 @@ jobs: - name: Run the tests if: startsWith(runner.os, 'Linux') - run: | - ./bin/test + run: BETTY_TEST_SKIP_PYINSTALLER=true ./bin/test shell: bash - name: Run the tests if: ${{ ! startsWith(runner.os, 'Linux') }} - run: | - BETTY_TEST_SKIP_SHELLCHECK=true BETTY_TEST_SKIP_FLAKE8=true BETTY_TEST_SKIP_MYPY=true BETTY_TEST_SKIP_STYLELINT=true BETTY_TEST_SKIP_ESLINT=true BETTY_TEST_SKIP_CYPRESS=true BETTY_TEST_SKIP_PYINSTALLER=true ./bin/test + run: BETTY_TEST_SKIP_SHELLCHECK=true BETTY_TEST_SKIP_FLAKE8=true BETTY_TEST_SKIP_MYPY=true BETTY_TEST_SKIP_STYLELINT=true BETTY_TEST_SKIP_ESLINT=true BETTY_TEST_SKIP_CYPRESS=true BETTY_TEST_SKIP_PYINSTALLER=true ./bin/test shell: bash - name: Upload code coverage