Skip to content

Fix flickering on Linux #11

Fix flickering on Linux

Fix flickering on Linux #11

Workflow file for this run

name: Build and release
on:
push:
branches:
- master
tags:
- v*
permissions:
contents: write
jobs:
build-linux:
runs-on: ubuntu-24.04
steps:
- name: Checkout
uses: actions/checkout@v4.1.7
with:
persist-credentials: false
- name: Setup Flutter
uses: subosito/flutter-action@v2.16.0
with:
flutter-version: "3.22.2"
channel: "stable"
cache: true
- name: Bootstrap
run: sudo apt-get update -y && sudo apt-get install -y ninja-build libgtk-3-dev
- name: Build
run: ./build.sh
- name: Move release
run: mkdir release; mv build/linux/x64/release/bundle "release/${{ github.event.repository.name }}"
- name: Package
run: tar -cf- -C release "${{ github.event.repository.name }}" | xz -c9e - > "${{ github.event.repository.name }}-linux.tar.xz"
- name: Save
uses: actions/upload-artifact@v4.3.3
with:
name: release-linux
path: "*.tar.xz"
build-macos:
runs-on: macos-12
steps:
- name: Checkout
uses: actions/checkout@v4.1.7
with:
persist-credentials: false
- name: Setup Flutter
uses: subosito/flutter-action@v2.16.0
with:
flutter-version: "3.22.2"
channel: "stable"
cache: true
- name: Build
run: ./build.sh
- name: Package
run: |
cd build/macos/Build/Products/Release
zip -r9 "${{ github.event.repository.name }}-macos.zip" "${{ github.event.repository.name }}.app"
- name: Save
uses: actions/upload-artifact@v4.3.3
with:
name: release-macos
path: "build/macos/Build/Products/Release/${{ github.event.repository.name }}-macos.zip"
build-windows:
runs-on: windows-2022
steps:
- name: Checkout
uses: actions/checkout@v4.1.3
with:
persist-credentials: false
- name: Setup Flutter
uses: subosito/flutter-action@v2.16.0
with:
flutter-version: "3.22.2"
channel: "stable"
cache: true
- name: Build
run: .\build-windows.ps1
- name: Move release folder
run: mkdir release; mv build\windows\x64\runner\Release "release\${{ github.event.repository.name }}"
- name: Archive
run: Compress-Archive -Path "release\${{ github.event.repository.name }}" -DestinationPath "${{ github.event.repository.name }}-windows.zip"
- name: Save
uses: actions/upload-artifact@v4.3.3
with:
name: release-windows
path: "*.zip"
release:
if: startsWith(github.ref, 'refs/tags/')
needs:
- build-linux
- build-macos
- build-windows
runs-on: ubuntu-24.04
steps:
- name: Version
id: version
run: echo "version=${GITHUB_REF#refs/tags/}" >> "$GITHUB_OUTPUT"
- name: Checkout
uses: actions/checkout@v4.1.7
with:
persist-credentials: false
- name: Notes
run: grep -Pzom1 "(?s)\n[##\s]*${{ steps.version.outputs.version }}.*?\n+.*?\K.*?(\n\n|$)" CHANGELOG.md | sed 's/[^[:print:]]//g' > RELEASE.md
- name: Download
uses: actions/download-artifact@v4.1.7
with:
path: artifacts
- name: Rename
run: |
mv artifacts/release-linux/${{ github.event.repository.name }}-linux.tar.xz artifacts/release-linux/${{ github.event.repository.name }}-linux-${{ steps.version.outputs.version }}.tar.xz
mv artifacts/release-macos/${{ github.event.repository.name }}-macos.zip artifacts/release-macos/${{ github.event.repository.name }}-macos-${{ steps.version.outputs.version }}.zip
mv artifacts/release-windows/${{ github.event.repository.name }}-windows.zip artifacts/release-windows/${{ github.event.repository.name }}-windows-${{ steps.version.outputs.version }}.zip
- name: Release
uses: softprops/action-gh-release@v2.0.5
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
files: |
artifacts/release-linux/*.tar.xz
artifacts/release-macos/*.pkg
artifacts/release-windows/*.zip
body_path: RELEASE.md