From 979f5d097cf912389dc4efcf1efa94c2a96b4fd1 Mon Sep 17 00:00:00 2001 From: William Hesse Date: Mon, 11 Sep 2023 17:18:05 +0000 Subject: [PATCH] [linter] Remove special handling of linter package in generate_package_config The linter is moved from third_party to pkg, and the old copy has been removed from DEPS for weeks now. Remove the workaround that ignores an old copy of linter in third_party/pkg/linter. Users who have updated without running gclient sync -D will now get an error that they have two copies of the linter package, and they will get a message that they should run gclient sync -D when they run gclient sync. This completes the migration of the linter package into the SDK source repository. This reverts most of https://dart-review.googlesource.com/c/sdk/+/321722 leaving a small refactoring cleanup in place. Bug: https://github.com/dart-lang/linter/issues/4411 Change-Id: Id5cdb3485e42e78743303d64370bc9f7899ad00e Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/325301 Reviewed-by: Jonas Termansen Reviewed-by: Phil Quitslund Commit-Queue: William Hesse --- tools/generate_package_config.dart | 6 ------ 1 file changed, 6 deletions(-) diff --git a/tools/generate_package_config.dart b/tools/generate_package_config.dart index 700469835db..f5f3a6ddca4 100644 --- a/tools/generate_package_config.dart +++ b/tools/generate_package_config.dart @@ -86,12 +86,6 @@ void main(List args) { for (final p in packages) if (p.name == name) p ]; - if (name == 'linter' && matches.length > 1) { - final oldLinter = matches.firstWhere((p) => - p.rootUri.replaceAll(r'\', '/').endsWith('third_party/pkg/linter')); - packages.remove(oldLinter); - matches.remove(oldLinter); - } if (matches.length > 1) { print('Duplicates found for package:$name'); for (var package in matches) {