- Fixed being unable to switch from offline back to online mode while… #250
This file contains hidden or 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: Deploy to GitHub Pages | |
| on: | |
| push: | |
| branches: [main, dev] | |
| workflow_dispatch: | |
| permissions: | |
| contents: read | |
| pages: write | |
| id-token: write | |
| concurrency: | |
| group: "pages" | |
| cancel-in-progress: false | |
| jobs: | |
| deploy: | |
| runs-on: ubuntu-latest | |
| environment: | |
| name: github-pages | |
| url: ${{ steps.deployment. outputs.page_url }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: subosito/flutter-action@v2 | |
| with: | |
| channel: 'stable' | |
| - name: Generate build version | |
| id: version | |
| run: echo "APP_VERSION=APP-$(date +%s)" >> $GITHUB_OUTPUT | |
| - run: flutter pub get | |
| - run: dart run build_runner build --delete-conflicting-outputs | |
| - run: flutter build web --release --base-href "/" --dart-define=API_KEY=${{ secrets.API_KEY }} --dart-define=APP_VERSION=${{ steps.version.outputs.APP_VERSION }} | |
| - uses: actions/configure-pages@v4 | |
| - uses: actions/upload-pages-artifact@v3 | |
| with: | |
| path: build/web | |
| - name: Deploy to GitHub Pages | |
| id: deployment | |
| uses: actions/deploy-pages@v4 |