This repository has been archived by the owner on Dec 6, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 92
63 lines (60 loc) · 2.01 KB
/
dart.yml
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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
name: dart-services
on:
# Run CI on pushes to the master branch, and on PRs against master.
push:
branches: [master]
pull_request:
branches: [master]
workflow_dispatch:
schedule:
- cron: "0 0 * * *" # Every day at midnight
jobs:
# Check code formatting, static analysis, and build on a single OS (linux)
# against Dart stable and beta.
analyze:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
sdk: [stable, beta, dev, old, master]
steps:
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9
- uses: dart-lang/setup-dart@d6a63dab3335f427404425de0fbfed4686d93c4f
with:
sdk: stable
- name: Install dependencies
run: sudo apt-get install -y protobuf-compiler redis
- name: Install dependencies
run: dart pub get
- name: Analyze code
run: dart analyze --fatal-infos .
- name: Prepare Flutter
run: |
dart run tool/update_sdk.dart ${{ matrix.sdk }}
export PATH=$PATH:$PWD/flutter-sdks/${{ matrix.sdk }}/bin
flutter doctor -v
flutter config --enable-web
- name: Run tests
run: |
export PATH=$PATH:$HOME/.pub-cache/bin
dart pub global activate protoc_plugin
./tool/travis.sh ${{ matrix.sdk }}
# Run the benchmarks on the bots to ensure they don't regress.
benchmark:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9
- uses: dart-lang/setup-dart@d6a63dab3335f427404425de0fbfed4686d93c4f
- run: sudo apt-get install -y protobuf-compiler redis
- run: dart pub get
- name: Download the Flutter SDK
run: |
dart run tool/update_sdk.dart stable
export PATH=$PATH:$PWD/flutter-sdks/stable/bin
flutter doctor -v
- name: Prep the repo
env:
FLUTTER_CHANNEL: stable
run: dart pub run grinder buildbot
- name: Run benchmarks
run: dart benchmark/bench.dart