Skip to content

Add CI/CD workflow for Flutter web #1

Add CI/CD workflow for Flutter web

Add CI/CD workflow for Flutter web #1

Workflow file for this run

name: Flutter Web CI/CD
on:
push:
branches:
- mainV1
jobs:
build-and-deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0
persist-credentials: true
- name: Setup Flutter
uses: subosito/flutter-action@v2
with:
flutter-version: 'stable'
- name: Install dependencies
run: flutter pub get
- name: Build web
run: flutter build web --release
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: build/web
publish_branch: gh-pages
commit_message: "CI: deploy Flutter web build"