Skip to content

Commit

Permalink
Merge remote-tracking branch 'google/master' into google#780
Browse files Browse the repository at this point in the history
  • Loading branch information
hacker1024 committed Feb 17, 2021
2 parents 8c1a3bd + 81d7abc commit 35745a7
Show file tree
Hide file tree
Showing 20 changed files with 321 additions and 56 deletions.
261 changes: 252 additions & 9 deletions .github/workflows/dart.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Created with package:mono_repo v3.4.5
# Created with package:mono_repo v3.4.6
name: Dart CI
on:
push:
Expand Down Expand Up @@ -33,11 +33,95 @@ jobs:
- id: checkout
uses: actions/checkout@v2
- name: mono_repo self validate
run: pub global activate mono_repo 3.4.5
run: pub global activate mono_repo 3.4.6
- name: mono_repo self validate
run: pub global run mono_repo generate --validate
job_002:
name: "analyzer_and_format; PKGS: _test_yaml, checked_yaml, example, json_annotation, json_serializable; `dartfmt -n --set-exit-if-changed .`, `dartanalyzer --fatal-infos .`"
name: "analyzer_and_format; Dart beta; PKGS: _test_yaml, checked_yaml, example, json_annotation, json_serializable; `dartfmt -n --set-exit-if-changed .`, `dartanalyzer --fatal-infos .`"
runs-on: ubuntu-latest
steps:
- name: Cache Pub hosted dependencies
uses: actions/cache@v2
with:
path: "~/.pub-cache/hosted"
key: "os:ubuntu-latest;pub-cache-hosted;dart:beta;packages:_test_yaml-checked_yaml-example-json_annotation-json_serializable;commands:dartfmt-dartanalyzer"
restore-keys: |
os:ubuntu-latest;pub-cache-hosted;dart:beta;packages:_test_yaml-checked_yaml-example-json_annotation-json_serializable
os:ubuntu-latest;pub-cache-hosted;dart:beta
os:ubuntu-latest;pub-cache-hosted
os:ubuntu-latest
- uses: dart-lang/setup-dart@v0.3
with:
sdk: beta
- id: checkout
uses: actions/checkout@v2
- id: _test_yaml_pub_upgrade
name: "_test_yaml; pub upgrade --no-precompile"
if: "always() && steps.checkout.conclusion == 'success'"
working-directory: _test_yaml
run: pub upgrade --no-precompile
- name: "_test_yaml; dartfmt -n --set-exit-if-changed ."
if: "always() && steps._test_yaml_pub_upgrade.conclusion == 'success'"
working-directory: _test_yaml
run: dartfmt -n --set-exit-if-changed .
- name: "_test_yaml; dartanalyzer --fatal-infos ."
if: "always() && steps._test_yaml_pub_upgrade.conclusion == 'success'"
working-directory: _test_yaml
run: dartanalyzer --fatal-infos .
- id: checked_yaml_pub_upgrade
name: "checked_yaml; pub upgrade --no-precompile"
if: "always() && steps.checkout.conclusion == 'success'"
working-directory: checked_yaml
run: pub upgrade --no-precompile
- name: "checked_yaml; dartfmt -n --set-exit-if-changed ."
if: "always() && steps.checked_yaml_pub_upgrade.conclusion == 'success'"
working-directory: checked_yaml
run: dartfmt -n --set-exit-if-changed .
- name: "checked_yaml; dartanalyzer --fatal-infos ."
if: "always() && steps.checked_yaml_pub_upgrade.conclusion == 'success'"
working-directory: checked_yaml
run: dartanalyzer --fatal-infos .
- id: example_pub_upgrade
name: "example; pub upgrade --no-precompile"
if: "always() && steps.checkout.conclusion == 'success'"
working-directory: example
run: pub upgrade --no-precompile
- name: "example; dartfmt -n --set-exit-if-changed ."
if: "always() && steps.example_pub_upgrade.conclusion == 'success'"
working-directory: example
run: dartfmt -n --set-exit-if-changed .
- name: "example; dartanalyzer --fatal-infos ."
if: "always() && steps.example_pub_upgrade.conclusion == 'success'"
working-directory: example
run: dartanalyzer --fatal-infos .
- id: json_annotation_pub_upgrade
name: "json_annotation; pub upgrade --no-precompile"
if: "always() && steps.checkout.conclusion == 'success'"
working-directory: json_annotation
run: pub upgrade --no-precompile
- name: "json_annotation; dartfmt -n --set-exit-if-changed ."
if: "always() && steps.json_annotation_pub_upgrade.conclusion == 'success'"
working-directory: json_annotation
run: dartfmt -n --set-exit-if-changed .
- name: "json_annotation; dartanalyzer --fatal-infos ."
if: "always() && steps.json_annotation_pub_upgrade.conclusion == 'success'"
working-directory: json_annotation
run: dartanalyzer --fatal-infos .
- id: json_serializable_pub_upgrade
name: "json_serializable; pub upgrade --no-precompile"
if: "always() && steps.checkout.conclusion == 'success'"
working-directory: json_serializable
run: pub upgrade --no-precompile
- name: "json_serializable; dartfmt -n --set-exit-if-changed ."
if: "always() && steps.json_serializable_pub_upgrade.conclusion == 'success'"
working-directory: json_serializable
run: dartfmt -n --set-exit-if-changed .
- name: "json_serializable; dartanalyzer --fatal-infos ."
if: "always() && steps.json_serializable_pub_upgrade.conclusion == 'success'"
working-directory: json_serializable
run: dartanalyzer --fatal-infos .
job_003:
name: "analyzer_and_format; Dart dev; PKGS: _test_yaml, checked_yaml, example, json_annotation, json_serializable; `dartfmt -n --set-exit-if-changed .`, `dartanalyzer --fatal-infos .`"
runs-on: ubuntu-latest
steps:
- name: Cache Pub hosted dependencies
Expand Down Expand Up @@ -120,8 +204,67 @@ jobs:
if: "always() && steps.json_serializable_pub_upgrade.conclusion == 'success'"
working-directory: json_serializable
run: dartanalyzer --fatal-infos .
job_003:
name: "unit_test; PKGS: _test_yaml, checked_yaml, example, json_serializable; `pub run test`"
job_004:
name: "unit_test; Dart beta; PKGS: _test_yaml, checked_yaml, example, json_serializable; `pub run test`"
runs-on: ubuntu-latest
steps:
- name: Cache Pub hosted dependencies
uses: actions/cache@v2
with:
path: "~/.pub-cache/hosted"
key: "os:ubuntu-latest;pub-cache-hosted;dart:beta;packages:_test_yaml-checked_yaml-example-json_serializable;commands:test_0"
restore-keys: |
os:ubuntu-latest;pub-cache-hosted;dart:beta;packages:_test_yaml-checked_yaml-example-json_serializable
os:ubuntu-latest;pub-cache-hosted;dart:beta
os:ubuntu-latest;pub-cache-hosted
os:ubuntu-latest
- uses: dart-lang/setup-dart@v0.3
with:
sdk: beta
- id: checkout
uses: actions/checkout@v2
- id: _test_yaml_pub_upgrade
name: "_test_yaml; pub upgrade --no-precompile"
if: "always() && steps.checkout.conclusion == 'success'"
working-directory: _test_yaml
run: pub upgrade --no-precompile
- name: _test_yaml; pub run test
if: "always() && steps._test_yaml_pub_upgrade.conclusion == 'success'"
working-directory: _test_yaml
run: pub run test
- id: checked_yaml_pub_upgrade
name: "checked_yaml; pub upgrade --no-precompile"
if: "always() && steps.checkout.conclusion == 'success'"
working-directory: checked_yaml
run: pub upgrade --no-precompile
- name: checked_yaml; pub run test
if: "always() && steps.checked_yaml_pub_upgrade.conclusion == 'success'"
working-directory: checked_yaml
run: pub run test
- id: example_pub_upgrade
name: "example; pub upgrade --no-precompile"
if: "always() && steps.checkout.conclusion == 'success'"
working-directory: example
run: pub upgrade --no-precompile
- name: example; pub run test
if: "always() && steps.example_pub_upgrade.conclusion == 'success'"
working-directory: example
run: pub run test
- id: json_serializable_pub_upgrade
name: "json_serializable; pub upgrade --no-precompile"
if: "always() && steps.checkout.conclusion == 'success'"
working-directory: json_serializable
run: pub upgrade --no-precompile
- name: json_serializable; pub run test
if: "always() && steps.json_serializable_pub_upgrade.conclusion == 'success'"
working-directory: json_serializable
run: pub run test
needs:
- job_001
- job_002
- job_003
job_005:
name: "unit_test; Dart dev; PKGS: _test_yaml, checked_yaml, example, json_serializable; `pub run test`"
runs-on: ubuntu-latest
steps:
- name: Cache Pub hosted dependencies
Expand Down Expand Up @@ -178,8 +321,41 @@ jobs:
needs:
- job_001
- job_002
job_004:
name: "unit_test; PKG: json_serializable; `pub run test -p chrome`"
- job_003
job_006:
name: "unit_test; Dart beta; PKG: json_serializable; `pub run test -p chrome`"
runs-on: ubuntu-latest
steps:
- name: Cache Pub hosted dependencies
uses: actions/cache@v2
with:
path: "~/.pub-cache/hosted"
key: "os:ubuntu-latest;pub-cache-hosted;dart:beta;packages:json_serializable;commands:test_2"
restore-keys: |
os:ubuntu-latest;pub-cache-hosted;dart:beta;packages:json_serializable
os:ubuntu-latest;pub-cache-hosted;dart:beta
os:ubuntu-latest;pub-cache-hosted
os:ubuntu-latest
- uses: dart-lang/setup-dart@v0.3
with:
sdk: beta
- id: checkout
uses: actions/checkout@v2
- id: json_serializable_pub_upgrade
name: "json_serializable; pub upgrade --no-precompile"
if: "always() && steps.checkout.conclusion == 'success'"
working-directory: json_serializable
run: pub upgrade --no-precompile
- name: "json_serializable; pub run test -p chrome"
if: "always() && steps.json_serializable_pub_upgrade.conclusion == 'success'"
working-directory: json_serializable
run: pub run test -p chrome
needs:
- job_001
- job_002
- job_003
job_007:
name: "unit_test; Dart dev; PKG: json_serializable; `pub run test -p chrome`"
runs-on: ubuntu-latest
steps:
- name: Cache Pub hosted dependencies
Expand Down Expand Up @@ -209,8 +385,72 @@ jobs:
needs:
- job_001
- job_002
job_005:
name: "ensure_build; PKGS: _test_yaml, checked_yaml, example, json_serializable; `pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart`"
- job_003
job_008:
name: "ensure_build; Dart beta; PKGS: _test_yaml, checked_yaml, example, json_serializable; `pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart`"
runs-on: ubuntu-latest
steps:
- name: Cache Pub hosted dependencies
uses: actions/cache@v2
with:
path: "~/.pub-cache/hosted"
key: "os:ubuntu-latest;pub-cache-hosted;dart:beta;packages:_test_yaml-checked_yaml-example-json_serializable;commands:test_1"
restore-keys: |
os:ubuntu-latest;pub-cache-hosted;dart:beta;packages:_test_yaml-checked_yaml-example-json_serializable
os:ubuntu-latest;pub-cache-hosted;dart:beta
os:ubuntu-latest;pub-cache-hosted
os:ubuntu-latest
- uses: dart-lang/setup-dart@v0.3
with:
sdk: beta
- id: checkout
uses: actions/checkout@v2
- id: _test_yaml_pub_upgrade
name: "_test_yaml; pub upgrade --no-precompile"
if: "always() && steps.checkout.conclusion == 'success'"
working-directory: _test_yaml
run: pub upgrade --no-precompile
- name: "_test_yaml; pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart"
if: "always() && steps._test_yaml_pub_upgrade.conclusion == 'success'"
working-directory: _test_yaml
run: pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart
- id: checked_yaml_pub_upgrade
name: "checked_yaml; pub upgrade --no-precompile"
if: "always() && steps.checkout.conclusion == 'success'"
working-directory: checked_yaml
run: pub upgrade --no-precompile
- name: "checked_yaml; pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart"
if: "always() && steps.checked_yaml_pub_upgrade.conclusion == 'success'"
working-directory: checked_yaml
run: pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart
- id: example_pub_upgrade
name: "example; pub upgrade --no-precompile"
if: "always() && steps.checkout.conclusion == 'success'"
working-directory: example
run: pub upgrade --no-precompile
- name: "example; pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart"
if: "always() && steps.example_pub_upgrade.conclusion == 'success'"
working-directory: example
run: pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart
- id: json_serializable_pub_upgrade
name: "json_serializable; pub upgrade --no-precompile"
if: "always() && steps.checkout.conclusion == 'success'"
working-directory: json_serializable
run: pub upgrade --no-precompile
- name: "json_serializable; pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart"
if: "always() && steps.json_serializable_pub_upgrade.conclusion == 'success'"
working-directory: json_serializable
run: pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart
needs:
- job_001
- job_002
- job_003
- job_004
- job_005
- job_006
- job_007
job_009:
name: "ensure_build; Dart dev; PKGS: _test_yaml, checked_yaml, example, json_serializable; `pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart`"
runs-on: ubuntu-latest
steps:
- name: Cache Pub hosted dependencies
Expand Down Expand Up @@ -269,3 +509,6 @@ jobs:
- job_002
- job_003
- job_004
- job_005
- job_006
- job_007
1 change: 1 addition & 0 deletions _test_yaml/mono_pkg.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# See https://github.com/google/mono_repo.dart for details on this file
dart:
- beta # change this to 1.12.0 when it's released!
- dev

stages:
Expand Down
4 changes: 1 addition & 3 deletions _test_yaml/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ dev_dependencies:
json_annotation: any
json_serializable: any
test: ^1.6.0
yaml: ^3.0.0

dependency_overrides:
checked_yaml:
Expand All @@ -19,6 +20,3 @@ dependency_overrides:
path: ../json_annotation
json_serializable:
path: ../json_serializable

# For yaml!
yaml: 3.0.0-nullsafety.0
2 changes: 1 addition & 1 deletion checked_yaml/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## 2.0.0-nullsafety-dev
## 2.0.0-dev

- *BREAKING* `checkedYamlDecode` `sourceUrl` parameter is now a `Uri`.
- Require at least Dart `2.12.0-0`.
Expand Down
1 change: 1 addition & 0 deletions checked_yaml/mono_pkg.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# See https://github.com/google/mono_repo.dart for details on this file
dart:
- beta # change this to 1.12.0 when it's released!
- dev

stages:
Expand Down
11 changes: 4 additions & 7 deletions checked_yaml/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: checked_yaml
version: 1.9.0-nullsafety-dev
version: 1.9.0-dev

description: >-
Generate more helpful exceptions when decoding YAML documents using
Expand All @@ -10,22 +10,19 @@ environment:

dependencies:
json_annotation: '>=2.2.0 <5.0.0'
source_span: ^1.8.0-nullsafety.4
yaml: ^3.0.0-nullsafety.0
source_span: ^1.8.0
yaml: ^3.0.0

dev_dependencies:
build_runner: ^1.0.0
build_verify: ^1.1.0
json_serializable: ^3.0.0
path: ^1.0.0
test: ^1.16.0-nullsafety.7
test: ^1.16.0
test_process: ^1.0.1

dependency_overrides:
json_annotation:
path: ../json_annotation
json_serializable:
path: ../json_serializable
# Need to force yaml for now due to dev dependencies
# build_runner -> build_config -> pubspec_parse
yaml: 3.0.0-nullsafety.0
4 changes: 2 additions & 2 deletions example/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@ dependencies to your `pubspec.yaml`.

```yaml
dependencies:
json_annotation: ^3.0.0
json_annotation: ^4.0.0

dev_dependencies:
build_runner: ^1.0.0
json_serializable: ^3.2.0
json_serializable: ^4.0.0
```
Annotate your code with classes defined in
Expand Down
1 change: 1 addition & 0 deletions example/mono_pkg.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# See https://github.com/google/mono_repo.dart for details on this file
dart:
- beta # change this to 1.12.0 when it's released!
- dev

stages:
Expand Down
Loading

0 comments on commit 35745a7

Please sign in to comment.