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

Unified Diff: utils/pub/sdk_source.dart

Issue 10704172: Hook in the version solver to pub install. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 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 | « utils/pub/repo_source.dart ('k') | utils/tests/pub/pub_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: utils/pub/sdk_source.dart
diff --git a/utils/pub/sdk_source.dart b/utils/pub/sdk_source.dart
index 3662f853fa4530280307cbfe9e5b2369fb43aa6c..3ca8effc422930ef96325ca54f17de82ce269405 100644
--- a/utils/pub/sdk_source.dart
+++ b/utils/pub/sdk_source.dart
@@ -6,7 +6,9 @@
#import('io.dart');
#import('package.dart');
+#import('pubspec.dart');
#import('source.dart');
+#import('version.dart');
/**
* A package source that uses libraries from the Dart SDK.
@@ -31,8 +33,10 @@ class SdkSource extends Source {
* revision number of the SDK itself.
*/
Future<Pubspec> describe(PackageId id) {
- return readTextFile(join(rootDir, "revision")).transform((revision) =>
- new Pubspec("0.0.0-r.${revision.trim()}", <PackageRef>[]));
+ return readTextFile(join(rootDir, "revision")).transform((revision) {
+ var version = new Version.parse("0.0.0-r.${revision.trim()}");
+ return new Pubspec(version, <PackageRef>[]);
+ });
}
/**
« no previous file with comments | « utils/pub/repo_source.dart ('k') | utils/tests/pub/pub_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698