Skip to content

Example project web/index.html fixed as per latest flutter guideline #27

Example project web/index.html fixed as per latest flutter guideline

Example project web/index.html fixed as per latest flutter guideline #27

Workflow file for this run

# Note:
# Make sure that the github pages is already set to Github Actions, otherwise the workflow will fail.
#
# Author: Shubham Gupta
# - GitHub: https://github.com/shubham-gupta-16/
name: CI
on:
push:
branches:
- master
# pull_request:
# branches:
# - master
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write
# Allow one concurrent deployment
concurrency:
group: "pages"
cancel-in-progress: true
jobs:
flutter_web_deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./example
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Flutter
uses: subosito/flutter-action@v2
with:
channel: 'stable'
- run: flutter pub get
- run: flutter build web --base-href /${{ github.event.repository.name }}/
- name: Upload artifact
uses: actions/upload-pages-artifact@v1
with:
path: example/build/web
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@main