-
Notifications
You must be signed in to change notification settings - Fork 0
45 lines (35 loc) · 1.18 KB
/
flutter-web.yml
File metadata and controls
45 lines (35 loc) · 1.18 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
name: Deploy Flutter Web to GitHub Pages
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
permissions:
contents: write
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Install Flutter SDK
# You may pin to the exact commit or the version.
# uses: monterail/flutter-action@8c0b4ae773b3a43022bbac48c30d7c67574bc2e6
uses: monterail/flutter-action@v1
with:
# Desired Flutter channel
channel: # optional, default is stable
- name: Install dependencies
run: flutter pub get
- name: Build Web
run: flutter build web --release --base-href "/Polizei-Flutter-Template/"
# Your project will need to have tests in test/ and a dependency on
# package:test for this step to succeed. Note that Flutter projects will
# want to change this to 'flutter test'.
- name: Run tests
run: flutter test
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: build/web