Chromium Code Reviews| Index: tools/migration/bin/check_for_splits.dart |
| diff --git a/tools/migration/bin/check_for_splits.dart b/tools/migration/bin/check_for_splits.dart |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..d6f627a490460d9bc4b2b6575de6c3c0b944f1a9 |
| --- /dev/null |
| +++ b/tools/migration/bin/check_for_splits.dart |
| @@ -0,0 +1,26 @@ |
| +// Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file |
| +// for details. All rights reserved. Use of this source code is governed by a |
| +// BSD-style license that can be found in the LICENSE file. |
| + |
| +import 'package:status_file/status_file.dart'; |
| + |
| +import 'package:migration/src/fork.dart'; |
| +import 'package:migration/src/io.dart'; |
| +import 'package:migration/src/log.dart'; |
| +import 'package:migration/src/migrate_statuses.dart'; |
| + |
| +const simpleDirs = const ["corelib", "language", "lib"]; |
| + |
| +void main(List<String> arguments) { |
|
bkonyi
2017/08/04 17:49:01
What's the point of this tool here exactly?
Bob Nystrom
2017/08/04 18:31:44
Oops, that was a temp script for me. Didn't mean t
|
| + for (var path in listFiles("language_2", extension: ".status")) { |
| + var file = new StatusFile.read(path); |
| + print(path); |
| + for (var section in file.sections) { |
| + var splits = filesForHeader(section.condition.toString()); |
| + if (splits.length > 1) { |
| + print("${section.lineNumber}: [ ${section.condition} ]"); |
| + print(" " + splits.join(" ")); |
| + } |
| + } |
| + } |
| +} |