Skip to content

Commit b22d3d6

Browse files
srawlinscommit-bot@chromium.org
authored andcommitted
Add a P2 migration script for null safety migrator
Change-Id: I2cf73ab09d13e205293f8445fd8f858eba125356 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/138884 Reviewed-by: Paul Berry <paulberry@google.com> Commit-Queue: Samuel Rawlins <srawlins@google.com>
1 parent db378a2 commit b22d3d6

2 files changed

Lines changed: 150 additions & 2 deletions

File tree

pkg/nnbd_migration/tool/trial_migration.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,12 @@
77

88
TRIAL_MIGRATION=`dirname "$0"`/trial_migration.dart
99

10-
# Priority One, Group One
10+
# Priority One, Group One, as defined at go/dart-null-safety-migration-order.
1111
p1g1 () {
1212
for n in charcode collection logging path pedantic term_glyph typed_data ; do
1313
echo "-g https://dart.googlesource.com/${n}.git"
1414
done
15-
# Some packages do not have googlesource mirrors, use github directly.
15+
# Some packages do not have googlesource mirrors; use GitHub directly.
1616
echo "-g https://github.com/google/vector_math.dart.git"
1717
# SDK-only packages.
1818
echo "-p meta"
Lines changed: 148 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,148 @@
1+
#!/usr/bin/env bash
2+
#
3+
# Copyright (c) 2020, the Dart project authors. Please see the AUTHORS file
4+
# for details. All rights reserved. Use of this source code is governed by a
5+
# BSD-style license that can be found in the LICENSE file.
6+
#
7+
8+
TRIAL_MIGRATION=`dirname "$0"`/trial_migration.dart
9+
10+
# Priority Two, Group One, as defined at go/dart-null-safety-migration-order.
11+
p2g1 () {
12+
echo "-g https://github.com/google/ansicolor-dart.git"
13+
echo "-g https://dart.googlesource.com/args.git"
14+
echo "-p dart_internal"
15+
echo "-g https://dart.googlesource.com/fixnum.git"
16+
echo "-g https://github.com/google/inject.dart.git"
17+
echo "-p js"
18+
echo "-g https://github.com/a14n/dart-js-wrapping.git"
19+
echo "-g https://dart.googlesource.com/mime.git"
20+
echo "-g https://github.com/xxgreg/mustache.git"
21+
echo "-g https://github.com/leonsenft/path_to_regexp.git"
22+
echo "-g https://github.com/petitparser/dart-petitparser.git"
23+
echo "-g https://github.com/google/platform.dart.git"
24+
echo "-g https://github.com/dart-lang/stream_transform.git"
25+
echo "-g https://github.com/dart-lang/sync_http.git"
26+
echo "-g https://github.com/srawlins/timezone.git"
27+
}
28+
29+
# Priority Two, Group Two, as defined at go/dart-null-safety-migration-order.
30+
p2g2 () {
31+
echo "-g https://github.com/google/ansicolor-dart.git"
32+
echo "-g https://dart.googlesource.com/cli_util.git"
33+
echo "-g https://github.com/dart-lang/clock.git"
34+
echo "-g https://github.com/kevmoo/completion.dart.git"
35+
echo "-g https://dart.googlesource.com/convert.git"
36+
echo "-g https://github.com/a14n/dart-google-maps.git"
37+
echo "-g https://github.com/dart-lang/http_server.git"
38+
echo "-g https://dart.googlesource.com/intl.git"
39+
echo "-p kernel"
40+
echo "-g https://dart.googlesource.com/package_config.git"
41+
# TODO(srawlins): Add protobuf, from monorepo
42+
# https://github.com/dart-lang/protobuf.
43+
echo "-g https://dart.googlesource.com/pub_semver.git"
44+
echo "-g https://github.com/google/quiver-dart.git"
45+
}
46+
47+
# Priority Two, Group Three, as defined at go/dart-null-safety-migration-order.
48+
p2g3 () {
49+
# TODO(srawlins): Add android_intent, from monorepo
50+
# https://github.com/flutter/plugins/tree/master/packages/android_intent.
51+
# SDK-only packages.
52+
echo "-g https://dart.googlesource.com/bazel_worker.git"
53+
echo "-g https://github.com/google/built_collection.dart.git"
54+
# TODO(srawlins): Add charts_common, from monorepo
55+
# https://github.com/google/charts/tree/master/charts_common.
56+
echo "-g https://github.com/jathak/cli_repl.git"
57+
echo "-g https://dart.googlesource.com/crypto.git"
58+
echo "-g https://dart.googlesource.com/csslib.git"
59+
echo "-g https://github.com/google/file.dart.git"
60+
# TODO(srawlins): Add front_end, which currently crashes.
61+
echo "-g https://github.com/reyerstudio/google-maps-markerclusterer.git"
62+
# TODO(srawlins): Add google_sign_in, from monorepo
63+
# https://github.com/flutter/plugins/tree/master/packages/google_sign_in.
64+
echo "-g https://dart.googlesource.com/http_multi_server.git"
65+
echo "-g https://github.com/dart-lang/observable.git"
66+
# TODO(srawlins): Add package_info, from monorepo
67+
# https://github.com/flutter/plugins/tree/master/packages/package_info.
68+
echo "-g https://dart.googlesource.com/pool.git"
69+
# TODO(srawlins): Add protoc_plugin, from monorepo
70+
# https://github.com/dart-lang/protobuf.
71+
echo "-g https://github.com/google/quiver-log.git"
72+
# TODO(srawlins): Add shared_preferences, from monorepo
73+
# https://github.com/flutter/plugins/tree/master/packages/shared_preferences.
74+
echo "-g https://dart.googlesource.com/source_maps.git"
75+
echo "-g https://dart.googlesource.com/string_scanner.git"
76+
echo "-g https://github.com/renggli/dart-xml.git"
77+
}
78+
79+
# Priority Two, Group Four, as defined at go/dart-null-safety-migration-order.
80+
p2g4 () {
81+
echo "-g https://github.com/brendan-duncan/archive.git"
82+
# TODO(srawlins): Add built_value, from monorepo
83+
# https://github.com/google/built_value.dart
84+
# Not including charted; concern is internal copy; not old published copy.
85+
echo "-g https://dart.googlesource.com/glob.git"
86+
echo "-g https://dart.googlesource.com/html.git"
87+
echo "-g https://dart.googlesource.com/http_parser.git"
88+
echo "-g https://dart.googlesource.com/json_rpc_2.git"
89+
# Not including observe; concern is internal copy; not old published copy.
90+
echo "-g https://github.com/google/process.dart.git"
91+
# Not including scissors; concern is internal copy; not old published copy.
92+
}
93+
94+
# Priority Two, Group Five, as defined at go/dart-null-safety-migration-order.
95+
p2g5 () {
96+
echo "-p analyzer"
97+
# Not including angular_forms; concern is internal copy; not old published copy.
98+
# Not including angular_router; concern is internal copy; not old published copy.
99+
# Not including angular_test; concern is internal copy; not old published copy.
100+
echo "-g https://github.com/dart-lang/code_builder.git"
101+
echo "-g https://dart.googlesource.com/http.git"
102+
echo "-g https://github.com/brendan-duncan/image.git"
103+
echo "-g https://dart.googlesource.com/shelf.git"
104+
}
105+
106+
# Priority Two, Group Six, as defined at go/dart-null-safety-migration-order.
107+
p2g6 () {
108+
echo "-p analyzer_plugin"
109+
# TODO(srawlins): Add build, from monorepo
110+
# https://github.com/dart-lang/build/tree/master/build.
111+
echo "-g https://github.com/dart-lang/coverage.git"
112+
echo "-g https://dart.googlesource.com/dart_style.git"
113+
# TODO(srawlins): Add flutter_test.
114+
echo "-g https://github.com/dart-lang/googleapis_auth.git"
115+
echo "-g https://github.com/dart-lang/intl_translation.git"
116+
echo "-g https://dart.googlesource.com/mockito.git"
117+
echo "-g https://dart.googlesource.com/package_resolver.git"
118+
# Not including pageloader ("2"); concern is internal copy; not old published copy.
119+
echo "-g https://dart.googlesource.com/shelf_static.git"
120+
echo "-g https://dart.googlesource.com/shelf_web_socket.git"
121+
}
122+
123+
# Priority Two, Group Seven, as defined at go/dart-null-safety-migration-order.
124+
p2g7 () {
125+
echo "-g https://github.com/dart-lang/grpc-dart.git"
126+
echo "-g https://github.com/google/pageloader.git" # This is pageloader3.
127+
echo "-g https://github.com/sass/dart-sass.git"
128+
echo "-g https://dart.googlesource.com/shelf_packages_handler.git"
129+
echo "-g https://github.com/dart-lang/source_gen.git"
130+
echo "-g https://dart.googlesource.com/source_map_stack_trace.git"
131+
}
132+
133+
# Priority Two, Group Eight, as defined at go/dart-null-safety-migration-order.
134+
p2g8 () {
135+
# Not including angular_compiler; concern is internal copy; not old published copy.
136+
# TODO(srawlins): Add built_value_generator, from monorepo
137+
# https://github.com/google/built_value.dart.
138+
# TODO(srawlins): Add flutter_tools, from monorepo
139+
# https://github.com/flutter/flutter.
140+
# TODO(srawlins): Locate and add rpc_client.
141+
echo ""
142+
}
143+
144+
# The current "official" set of parameters for the trial_migration script.
145+
set -x
146+
dart --enable-asserts ${TRIAL_MIGRATION} \
147+
$(p2g1) $(p2g2) $(p2g3) $(p2g4) $(p2g5) $(p2g6) $(p2g7) $(p2g8) \
148+
"$@"

0 commit comments

Comments
 (0)