Skip to content

chore(deps): bump build_runner from 2.4.7 to 2.4.8 #28

chore(deps): bump build_runner from 2.4.7 to 2.4.8

chore(deps): bump build_runner from 2.4.7 to 2.4.8 #28

name: Build and Deploy Web Platform
on:
push:
branches:
- master
env:
FLUTTER_VERSION: "3.16.x"
jobs:
build_on_web:
name: Build on Web
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- uses: subosito/[email protected]
with:
flutter-version: ${{env.FLUTTER_VERSION}}
channel: "stable"
- name: Create env.json
id: create-json
uses: jsdaniell/[email protected]
with:
name: "env.json"
json: '{"SUPABASE_URL":"${{secrets.SUPABASE_URL}}", "SUPABASE_ANON":"${{secrets.SUPABASE_ANON}}"}'
- name: Enable desktop platform
run: |
flutter config --enable-linux-desktop
flutter config --enable-windows-desktop
flutter config --enable-macos-desktop
flutter config --enable-web
- name: Install project dependencies
run: flutter pub get
- name: Generate intermediates
run: flutter pub run build_runner build --delete-conflicting-outputs
- name: Get version
id: version
uses: NiklasLehnfeld/flutter-version-number-action@main
- name: Build artifacts
run: flutter build web --dart-define-from-file=env.json --no-tree-shake-icons
- name: Package Release
uses: thedoctor0/zip-release@master
with:
type: "zip"
filename: app_creaty-${{ steps.version.outputs.version-number }}-web.zip
directory: build/web
- name: Release to github
uses: softprops/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
name: v${{ steps.version.outputs.version-number }}
tag_name: ${{ steps.version.outputs.version-number }}
generate_release_notes: true
files: build/web/app_creaty-${{ steps.version.outputs.version-number }}-web.zip
- name: Deploy to Netlify
uses: nwtgck/[email protected]
with:
publish-dir: "./build/web"
production-branch: master
github-token: ${{ secrets.GITHUB_TOKEN }}
deploy-message: "Deploy from GitHub Actions"
enable-pull-request-comment: false
enable-commit-comment: true
overwrites-pull-request-comment: true
env:
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_ACCESS_TOKEN }}
NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }}
timeout-minutes: 1