Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(246)

Unified Diff: pkg/analyzer_cli/lib/src/driver.dart

Issue 2366913002: Revert "Issue 27375. Use ContextBuilder to find analysis options file in analyzer_cli." (Closed)
Patch Set: Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer_cli/lib/src/driver.dart
diff --git a/pkg/analyzer_cli/lib/src/driver.dart b/pkg/analyzer_cli/lib/src/driver.dart
index 9e32cf0d951015241c42ad50e8f87bdbd0db9a51..ec779a7eb8dda662d1fdfe4fb65c148d403fe406 100644
--- a/pkg/analyzer_cli/lib/src/driver.dart
+++ b/pkg/analyzer_cli/lib/src/driver.dart
@@ -744,8 +744,12 @@ class Driver implements CommandLineStarter {
exitCode: ErrorSeverity.ERROR.ordinal);
}
} else {
- return new ContextBuilder(resourceProvider, null, null)
- .getOptionsFile(options.sourceFiles.first);
+ filePath = AnalysisEngine.ANALYSIS_OPTIONS_FILE;
+ file = resourceProvider.getFile(filePath);
+ if (!file.exists) {
+ filePath = AnalysisEngine.ANALYSIS_OPTIONS_YAML_FILE;
+ file = resourceProvider.getFile(filePath);
+ }
}
return file;
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698