diff --git a/.github/workflows/dart.yml b/.github/workflows/dart.yml index 2e035bd37..e081fd06b 100644 --- a/.github/workflows/dart.yml +++ b/.github/workflows/dart.yml @@ -1,4 +1,4 @@ -# Created with package:mono_repo v3.3.0 +# Created with package:mono_repo v3.4.1 name: Dart CI on: push: @@ -30,13 +30,14 @@ jobs: - uses: cedx/setup-dart@v2 with: release-channel: stable - version: latest - run: dart --version - uses: actions/checkout@v2 - - run: pub global activate mono_repo 3.3.0 - - run: pub global run mono_repo generate --validate + - name: mono_repo self validate + run: pub global activate mono_repo 3.4.1 + - name: mono_repo self validate + run: pub global run mono_repo generate --validate job_002: - name: "OS: linux; SDK: dev; PKGS: _test_yaml, checked_yaml, example, json_annotation, json_serializable; TASKS: [`dartfmt -n --set-exit-if-changed .`, `dartanalyzer --fatal-infos .`]" + name: "analyzer_and_format; 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 @@ -54,12 +55,68 @@ jobs: release-channel: dev - run: dart --version - uses: actions/checkout@v2 - - env: - PKGS: _test_yaml checked_yaml example json_annotation json_serializable - TRAVIS_OS_NAME: linux - run: tool/ci.sh dartfmt dartanalyzer + - id: _test_yaml_pub_upgrade + name: "_test_yaml; pub upgrade --no-precompile" + working-directory: _test_yaml + run: pub upgrade --no-precompile + - name: "_test_yaml; dartfmt -n --set-exit-if-changed ." + if: "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: "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" + working-directory: checked_yaml + run: pub upgrade --no-precompile + - name: "checked_yaml; dartfmt -n --set-exit-if-changed ." + if: "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: "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" + working-directory: example + run: pub upgrade --no-precompile + - name: "example; dartfmt -n --set-exit-if-changed ." + if: "steps.example_pub_upgrade.conclusion == 'success'" + working-directory: example + run: dartfmt -n --set-exit-if-changed . + - name: "example; dartanalyzer --fatal-infos ." + if: "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" + working-directory: json_annotation + run: pub upgrade --no-precompile + - name: "json_annotation; dartfmt -n --set-exit-if-changed ." + if: "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: "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" + working-directory: json_serializable + run: pub upgrade --no-precompile + - name: "json_serializable; dartfmt -n --set-exit-if-changed ." + if: "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: "steps.json_serializable_pub_upgrade.conclusion == 'success'" + working-directory: json_serializable + run: dartanalyzer --fatal-infos . job_003: - name: "OS: linux; SDK: dev; PKGS: _test_yaml, checked_yaml, example, json_serializable; TASKS: `pub run test`" + name: "unit_test; PKGS: _test_yaml, checked_yaml, example, json_serializable; `pub run test`" runs-on: ubuntu-latest steps: - name: Cache Pub hosted dependencies @@ -77,15 +134,43 @@ jobs: release-channel: dev - run: dart --version - uses: actions/checkout@v2 - - env: - PKGS: _test_yaml checked_yaml example json_serializable - TRAVIS_OS_NAME: linux - run: tool/ci.sh test_0 + - id: _test_yaml_pub_upgrade + name: "_test_yaml; pub upgrade --no-precompile" + working-directory: _test_yaml + run: pub upgrade --no-precompile + - name: _test_yaml; pub run test + if: "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" + working-directory: checked_yaml + run: pub upgrade --no-precompile + - name: checked_yaml; pub run test + if: "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" + working-directory: example + run: pub upgrade --no-precompile + - name: example; pub run test + if: "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" + working-directory: json_serializable + run: pub upgrade --no-precompile + - name: json_serializable; pub run test + if: "steps.json_serializable_pub_upgrade.conclusion == 'success'" + working-directory: json_serializable + run: pub run test needs: - job_001 - job_002 - job_005: - name: "OS: linux; SDK: dev; PKG: json_serializable; TASKS: `pub run test -p chrome`" + job_004: + name: "unit_test; PKG: json_serializable; `pub run test -p chrome`" runs-on: ubuntu-latest steps: - name: Cache Pub hosted dependencies @@ -103,15 +188,19 @@ jobs: release-channel: dev - run: dart --version - uses: actions/checkout@v2 - - env: - PKGS: json_serializable - TRAVIS_OS_NAME: linux - run: tool/ci.sh test_2 + - id: json_serializable_pub_upgrade + name: "json_serializable; pub upgrade --no-precompile" + working-directory: json_serializable + run: pub upgrade --no-precompile + - name: "json_serializable; pub run test -p chrome" + if: "steps.json_serializable_pub_upgrade.conclusion == 'success'" + working-directory: json_serializable + run: pub run test -p chrome needs: - job_001 - job_002 - job_004: - name: "OS: linux; SDK: dev; PKGS: _test_yaml, checked_yaml, example, json_serializable; TASKS: `pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart`" + 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`" runs-on: ubuntu-latest steps: - name: Cache Pub hosted dependencies @@ -129,10 +218,38 @@ jobs: release-channel: dev - run: dart --version - uses: actions/checkout@v2 - - env: - PKGS: _test_yaml checked_yaml example json_serializable - TRAVIS_OS_NAME: linux - run: tool/ci.sh test_1 + - id: _test_yaml_pub_upgrade + name: "_test_yaml; pub upgrade --no-precompile" + 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: "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" + 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: "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" + working-directory: example + run: pub upgrade --no-precompile + - name: "example; pub run test --run-skipped -t presubmit-only test/ensure_build_test.dart" + if: "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" + 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: "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_003 - - job_005 + - job_004 diff --git a/checked_yaml/changelog.md b/checked_yaml/CHANGELOG.md similarity index 76% rename from checked_yaml/changelog.md rename to checked_yaml/CHANGELOG.md index aef7f9af4..989d697b2 100644 --- a/checked_yaml/changelog.md +++ b/checked_yaml/CHANGELOG.md @@ -3,6 +3,11 @@ - *BREAKING* `checkedYamlDecode` `sourceUrl` parameter is now a `Uri`. - Require at least Dart `2.12.0-0`. +## 1.0.3 + +- Require at least Dart `2.7.0`. +- Allow `package:json_annotation` `v4.x`. + ## 1.0.2 - Require at least Dart `2.3.0`. diff --git a/checked_yaml/readme.md b/checked_yaml/README.md similarity index 100% rename from checked_yaml/readme.md rename to checked_yaml/README.md diff --git a/checked_yaml/pubspec.yaml b/checked_yaml/pubspec.yaml index 7422c6db2..1844da291 100644 --- a/checked_yaml/pubspec.yaml +++ b/checked_yaml/pubspec.yaml @@ -1,5 +1,6 @@ name: checked_yaml version: 1.9.0-nullsafety-dev + description: >- Generate more helpful exceptions when decoding YAML documents using package:json_serializable and package:yaml. @@ -8,7 +9,7 @@ environment: sdk: '>=2.12.0-0 <3.0.0' dependencies: - json_annotation: '>=2.2.0 <4.0.0' + json_annotation: '>=2.2.0 <5.0.0' source_span: ^1.8.0-nullsafety.4 yaml: ^3.0.0-nullsafety.0 diff --git a/checked_yaml/test/readme_test.dart b/checked_yaml/test/readme_test.dart index aaf6f6512..573db78f6 100644 --- a/checked_yaml/test/readme_test.dart +++ b/checked_yaml/test/readme_test.dart @@ -13,7 +13,7 @@ import 'package:test_process/test_process.dart'; final _examplePath = p.join('example', 'example.dart'); -final _readmeContent = File('readme.md').readAsStringSync(); +final _readmeContent = File('README.md').readAsStringSync(); final _exampleContent = File(_examplePath).readAsStringSync(); const _memberEnd = '\n}'; diff --git a/tool/ci.sh b/tool/ci.sh index fefe1576b..ad9db70ec 100755 --- a/tool/ci.sh +++ b/tool/ci.sh @@ -1,5 +1,5 @@ #!/bin/bash -# Created with package:mono_repo v3.3.0 +# Created with package:mono_repo v3.4.1 # Support built in commands on windows out of the box. function pub() {