-
Notifications
You must be signed in to change notification settings - Fork 102
/
melos.yaml
162 lines (146 loc) · 4.87 KB
/
melos.yaml
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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
name: FirebaseUI
repository: https://github.com/firebase/FirebaseUI-Flutter
packages:
- packages/*
- packages/*/example
- tests
command:
version:
linkToCommits: true
workspaceChangelog: true
changelogCommitBodies:
include: true
bootstrap:
runPubGetInParallel: false
usePubspecOverrides: true
scripts:
lint:
run: melos run analyze && melos run format
description: Run all static analysis checks.
analyze:
run: |
melos exec -- dart analyze . --fatal-infos
description: |
Run `dart analyze` in all packages.
format:
run: |
dart pub global run flutter_plugin_tools format && swiftformat .
description: |
Formats the code of all packages (Java, Objective-C, and Dart).
- Requires `flutter_plugin_tools` (`pub global activate flutter_plugin_tools`).
- Requires `git`.
- Requires `clang-format` (can be installed via Brew on MacOS).
- Requires `swiftformat` (can be installed via Brew on macOS).
test:
run: |
melos run test:unit:all
description: |
Run all tests available.
test:unit:all:
run: |
melos run test:unit --no-select && \
melos run test:unit:web --no-select
description: Run unit tests for all packages.
packageFilters:
dirExists:
- test
test:unit:
run: |
melos exec -c 6 --fail-fast -- "flutter test"
description: Run `flutter test` for a specific package.
packageFilters:
dirExists:
- test
test:unit:web:
run: |
melos exec -c 1 --fail-fast -- "flutter test --platform=chrome"
description: Run `flutter test --platform=chrome`.
packageFilters:
dirExists:
- test
test:build:web:
run: |
melos exec -c 1 --fail-fast -- \
"cd example && flutter build web"
description: |
Build all example apps for web platform
packageFilters:
dirExists:
- example
test:e2e:
working-directory: tests
run: cd tests && flutter test integration_test/firebase_ui_test.dart -r github -d
# Additional cleanup lifecycle script, executed when `melos clean` is run.
postclean: >
melos exec -c 6 -- "flutter clean"
add-license-header:
# If you add here another --ignore flag, add it also to
# "check-license-header".
run: |
addlicense -f header_template.txt \
--ignore "**/*.yml" \
--ignore "**/*.yaml" \
--ignore "**/*.xml" \
--ignore "**/*.g.dart" \
--ignore "**/*.sh" \
--ignore "**/*.html" \
--ignore "**/*.js" \
--ignore "**/*.ts" \
--ignore "**/*.g.h" \
--ignore "**/*.g.m" \
--ignore "**/*.rb" \
--ignore "**/*.txt" \
--ignore "**/*.cmake" \
--ignore "**/Runner/AppDelegate.swift" \
--ignore "**/Runner/MainFlutterWindow.swift" \
--ignore "**/Runner/Runner-Bridging-Header.h" \
--ignore "**/Runner/AppDelegate.h" \
--ignore "**/Runner/AppDelegate.m" \
--ignore "**/Runner/main.m" \
--ignore "**/MainActivity.kt" \
--ignore "**/MainActivity.java" \
--ignore "**/FlutterMultiDexApplication.java" \
--ignore "**/GeneratedPluginRegistrant.swift" \
--ignore "**/Pods/**" \
--ignore "**/flutter/generated_plugin_registrant.h" \
--ignore "**/flutter/generated_plugin_registrant.cc" \
.
description: Add a license header to all necessary files.
check-license-header:
# If you add here another --ignore flag, add it also to
# "add-license-header".
run: |
addlicense -f header_template.txt \
--check \
--ignore "**/*.yml" \
--ignore "**/*.yaml" \
--ignore "**/*.xml" \
--ignore "**/*.g.dart" \
--ignore "**/*.sh" \
--ignore "**/*.html" \
--ignore "**/*.js" \
--ignore "**/*.ts" \
--ignore "**/*.g.h" \
--ignore "**/*.g.m" \
--ignore "**/*.rb" \
--ignore "**/*.txt" \
--ignore "**/*.cmake" \
--ignore "**/Runner/AppDelegate.swift" \
--ignore "**/Runner/MainFlutterWindow.swift" \
--ignore "**/Runner/Runner-Bridging-Header.h" \
--ignore "**/Runner/AppDelegate.h" \
--ignore "**/Runner/AppDelegate.m" \
--ignore "**/Runner/main.m" \
--ignore "**/MainActivity.kt" \
--ignore "**/MainActivity.java" \
--ignore "**/FlutterMultiDexApplication.java" \
--ignore "**/GeneratedPluginRegistrant.swift" \
--ignore "**/Pods/**" \
--ignore "**/flutter/generated_plugin_registrant.*" \
--ignore "**/example/windows/**/*" \
.
description: Add a license header to all necessary files.
emulator:start:
run: firebase emulators:start --only firestore,auth,functions,storage,database --import=./emulators-data --export-on-exit=./emulators-data
update-dependencies:
run: dart scripts/update_dependencies.dart