scripts #262
This file contains 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: Build Windows | |
on: | |
push: | |
branches: | |
- main | |
- dev | |
jobs: | |
build: | |
runs-on: windows-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
with: | |
submodules: recursive | |
- name: Setup Flutter | |
uses: subosito/flutter-action@v2 | |
with: | |
flutter-version: '3.22.2' | |
- name: Update Build Number | |
run: | | |
git fetch --prune --unshallow | |
commit_count=$(git rev-list --count HEAD) | |
(Get-Content pubspec.yaml) -replace 'version: (.*)\+.*', 'version: $1+' + $commit_count | Set-Content pubspec.yaml | |
- name: Install dependencies | |
run: | | |
choco install -y cmake ninja | |
- name: Install Vulkan SDK | |
uses: humbletim/install-vulkan-sdk@v1.1.1 | |
with: | |
version: latest | |
cache: true | |
- name: Build Windows App | |
run: | | |
flutter pub get | |
flutter build windows | |
- name: Upload Windows Build | |
uses: actions/upload-artifact@v4 | |
with: | |
name: maid-windows | |
path: build/windows/x64/bundle |