Release #1
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Release | |
| # Build the Linux packages (.deb, .rpm, .tar.gz) and publish them to a GitHub | |
| # Release whenever a version tag (e.g. v1.1.0) is pushed. | |
| on: | |
| push: | |
| tags: | |
| - 'v*' | |
| workflow_dispatch: {} | |
| permissions: | |
| contents: write | |
| jobs: | |
| build-and-release: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Install Linux build dependencies | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y --no-install-recommends \ | |
| clang cmake ninja-build pkg-config \ | |
| libgtk-3-dev liblzma-dev \ | |
| rpm binutils | |
| - name: Set up Flutter | |
| uses: subosito/flutter-action@v2 | |
| with: | |
| channel: stable | |
| cache: true | |
| - name: Enable Linux desktop | |
| run: flutter config --enable-linux-desktop | |
| - name: Install Dart/Flutter dependencies | |
| run: flutter pub get | |
| - name: Verify (analyze + test) | |
| run: | | |
| flutter analyze | |
| flutter test | |
| - name: Build release packages | |
| run: packaging/build-release.sh | |
| - name: List artifacts | |
| run: ls -lh dist/*.deb dist/*.rpm dist/*.tar.gz | |
| - name: Publish GitHub Release | |
| if: startsWith(github.ref, 'refs/tags/') | |
| uses: softprops/action-gh-release@v2 | |
| with: | |
| generate_release_notes: true | |
| fail_on_unmatched_files: true | |
| files: | | |
| dist/*.deb | |
| dist/*.rpm | |
| dist/*.tar.gz |