Skip to content
This repository has been archived by the owner on Jul 2, 2024. It is now read-only.

Update to Dart 2.13 #22

Merged
merged 2 commits into from
Sep 14, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM google/dart:2.7.2 as build
FROM google/dart:2.13.4 as build
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Using the google image for open source projects


# Build Environment Vars
ARG BUILD_ID
Expand All @@ -19,7 +19,7 @@ RUN echo "Starting the script sections" && \
pub get && \
dartfmt --set-exit-if-changed --dry-run lib bin test tool && \
pub run dependency_validator -x upgrade/ -i dart_dev && \
dartanalyzer bin lib test && \
pub run dart_dev analyze && \
pub run abide || echo Abide would have failed CI. && \
pub run test --concurrency=4 -p vm --reporter=expanded test/vm/ && \
tar czvf abide.pub.tgz LICENSE README.md pubspec.yaml analysis_options.yaml lib/ bin/ && \
Expand Down
6 changes: 3 additions & 3 deletions lib/src/util.dart
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@
// limitations under the License.

import 'dart:async';
import 'dart:convert';
import 'dart:io';

import 'package:abide/src/constants.dart';
import 'package:abide/src/result.dart';
import 'package:dart2_constant/convert.dart' as convert;
import 'package:meta/meta.dart';
import 'package:resource/resource.dart';
import 'package:yaml/yaml.dart';
Expand Down Expand Up @@ -253,8 +253,8 @@ bool checkIfStrongModeIsSet(YamlMap analysisOptions) {
}

Future<Null> writeAbideJson(AbideResult result) async {
String json = convert.json.encode(result);
String s = json.encode(result);
final String file = '${Directory.current.path}/abide.json';
print('Writing $file');
new File(file).writeAsStringSync(json);
new File(file).writeAsStringSync(s);
}
5 changes: 2 additions & 3 deletions pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,14 @@ description: A command line tool to manage analysis_options.yaml and check if it
homepage: https://github.com/Workiva/abide

environment:
sdk: '>=1.23.0 <3.0.0'
sdk: ">=2.11.0 <3.0.0"

executables:
abide:

dependencies:
args: ^1.4.4
dart2_constant: ^1.0.0
meta: ^1.2.2
meta: '>=1.2.2 <1.7.0'
resource: ^2.0.0
yaml: ^2.1.12

Expand Down
2 changes: 1 addition & 1 deletion test/fixtures/dart1_project/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ homepage: https://github.com/Workiva/mock_name
publish_to: https://pub.workiva.org

environment:
sdk: '>=1.23.0 <2.0.0'
sdk: ">=2.11.0 <3.0.0"

dependencies:
browser: any
2 changes: 1 addition & 1 deletion test/fixtures/dart2_project/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@ homepage: https://github.com/Workiva/mock_name
publish_to: https://pub.workiva.org

environment:
sdk: '>=1.23.0 <3.0.0'
sdk: ">=2.11.0 <3.0.0"
2 changes: 1 addition & 1 deletion upgrade/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ description: A command line tool to update abide.yaml
homepage: https://github.com/Workiva/abide

environment:
sdk: '>=2.0.0 <3.0.0'
sdk: ">=2.11.0 <3.0.0"

executables:
abide_upgrade: upgrade
Expand Down