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

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

Issue 303153002: "Reverting 36776" (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 7 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/lib/src/library_helpers.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/docgen/lib/src/generator.dart
diff --git a/pkg/docgen/lib/src/generator.dart b/pkg/docgen/lib/src/generator.dart
index 06a991e2c4726ab77cf9d7e6ab22d9b7ac4c60df..0531869abdfdc8159e716ef3f0877acb27e5583a 100644
--- a/pkg/docgen/lib/src/generator.dart
+++ b/pkg/docgen/lib/src/generator.dart
@@ -26,7 +26,7 @@ import 'exports/source_mirrors.dart';
import 'io.dart';
import 'library_helpers.dart';
import 'models.dart';
-import 'package_helpers.dart';
+import 'package_helpers.dart' show packageNameFor, rootDirectory;
const String DEFAULT_OUTPUT_DIRECTORY = 'docs';
@@ -203,8 +203,7 @@ void _documentLibraries(List<LibraryMirror> libs, bool includeSdk,
'libraries': filteredEntities.where((e) => e is Library).map((e) =>
e.previewMap).toList(),
'introduction': _readIntroductionFile(introFileName, includeSdk),
- 'filetype': 'json',
- 'sdkVersion': packageVersion(coreLibrary.mirror)
+ 'filetype': 'json'
};
var encoder = new JsonEncoder.withIndent(indentJson ? ' ' : null);
@@ -296,8 +295,8 @@ String _obtainPackageRoot(String packageRoot, bool parseSdk,
var type = FileSystemEntity.typeSync(files.first);
if (type == FileSystemEntityType.DIRECTORY) {
var files2 = listDir(files.first, recursive: true);
- // Return '' means that there was no pubspec.yaml and therefore no
- // packageRoot.
+ // Return '' means that there was no pubspec.yaml and therefor no p
+ // ackageRoot.
packageRoot = files2.firstWhere((f) => f.endsWith(
'${path.separator}pubspec.yaml'), orElse: () => '');
if (packageRoot != '') {
« no previous file with comments | « no previous file | pkg/docgen/lib/src/library_helpers.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698