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

Unified Diff: pkg/docgen/lib/docgen.dart

Issue 20777002: Moved deleting directory to whenComplete (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 5 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 | pkg/docgen/test/single_library_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/docgen/lib/docgen.dart
diff --git a/pkg/docgen/lib/docgen.dart b/pkg/docgen/lib/docgen.dart
index dc7069fc2a19920dfd0121bad57de79256c9d949..6ad260988ed81ff2477cc6d544e4242bf6a8e149 100644
--- a/pkg/docgen/lib/docgen.dart
+++ b/pkg/docgen/lib/docgen.dart
@@ -154,17 +154,10 @@ Future<MirrorSystem> getMirrorSystem(List<String> args, {String packageRoot,
bool parseSdk:false}) {
var libraries = !parseSdk ? _listLibraries(args) : _listSdk();
if (libraries.isEmpty) throw new StateError('No Libraries.');
- // DART_SDK should be set to the root of the SDK library.
- var sdkRoot = Platform.environment['DART_SDK'];
- if (sdkRoot != null) {
- logger.info('Using DART_SDK to find SDK at $sdkRoot');
- } else {
- // If DART_SDK is not defined in the environment,
- // assuming the dart executable is from the Dart SDK folder inside bin.
- sdkRoot = path.join(path.dirname(path.dirname(path.dirname(path.dirname(
+ // Finds the root of SDK library based off the location of docgen.
+ var sdkRoot = path.join(path.dirname(path.dirname(path.dirname(path.dirname(
path.absolute(new Options().script))))), 'sdk');
- logger.info('SDK Root: ${sdkRoot}');
- }
+ logger.info('SDK Root: ${sdkRoot}');
return _analyzeLibraries(libraries, sdkRoot, packageRoot: packageRoot);
}
« no previous file with comments | « no previous file | pkg/docgen/test/single_library_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698