-
Notifications
You must be signed in to change notification settings - Fork 38
/
melos.yaml
102 lines (85 loc) · 2.75 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
# yaml-language-server: $schema=./schemas/melos.yaml.schema.json
name: mix_workspace
sdkPath: .fvm/flutter_sdk
packages:
- packages/*
- packages/*/example
- examples/*
- packages/*/demo
command:
bootstrap:
environment:
sdk: ">=3.3.0 <4.0.0"
flutter: ">=3.19.0"
dev_dependencies:
flutter_lints: ^4.0.0
dart_code_metrics_presets: ^2.14.0
build_runner: ^2.4.9
publish:
hooks:
pre: melos run gen:build
scripts:
# ANALYSIS
analyze:
run: melos run analyze:dart && melos run analyze:dcm
description: Run all static analysis checks.
exec:
failFast: true
analyze:dart:
run: melos exec -c 4 -- dart analyze .
description: Run Dart static analysis checks.
analyze:dcm:
run: melos exec -c 4 -- dcm analyze . --fatal-style --fatal-performance --fatal-warnings
description: Run DCM static analysis checks.
packageFilters:
dependsOn: "dart_code_metrics_presets"
lint:fix:all:
run: melos run lint:dart:fix && melos run lint:dcm:fix
description: Run all static analysis checks and apply fixes.
lint:dart:fix:
run: melos exec -- dart fix --apply .
description: Run Dart static analysis checks.
lint:dcm:fix:
run: melos exec -- dcm fix .
description: Run DCM static analysis checks.
packageFilters:
dependsOn: "dart_code_metrics_presets"
gen:watch:
run: melos exec --order-dependents -- dart run build_runner watch --delete-conflicting-outputs
description: Generate code for all packages
packageFilters:
dependsOn: "build_runner"
gen:build:
run: melos run gen:clean && melos exec --order-dependents -- dart run build_runner build --delete-conflicting-outputs
description: Generate code for all packages
packageFilters:
dependsOn: "build_runner"
gen:clean:
run: melos exec --order-dependents -- dart run build_runner clean
description: Clean generated code for all packages
packageFilters:
dependsOn: "build_runner"
test:
run: melos exec -- flutter test
description: Run flutter test
packageFilters:
dirExists: test
test:coverage:
run: melos exec -- flutter test --coverage
description: Run flutter test with coverage
packageFilters:
dirExists: test
brb:
run: melos run gen:build
brbc:
run: melos run gen:clean
fix:
run: melos run lint:fix:all
custom_lint_analyze:
run: melos exec --depends-on="mix_lint" dart pub run custom_lint
exports:
run: melos exec --scope="mix" --scope="remix" dart run ../../scripts/exports.dart .
description: Generate exports for the mix package
verify_version_pubspec_changelog:
run: ./scripts/verify_changelogs.sh packages
description: Verify that all packages have the same version