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

Unified Diff: utils/pub/lock_file.dart

Issue 12280019: Revert "Support relative paths in path dependencies." (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 10 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/io.dart ('k') | utils/pub/path_source.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: utils/pub/lock_file.dart
diff --git a/utils/pub/lock_file.dart b/utils/pub/lock_file.dart
index 594e523d357641cf24a96418e556f147e427e909..23e709993e18d1bb8499f3ba5844b6364f9e214e 100644
--- a/utils/pub/lock_file.dart
+++ b/utils/pub/lock_file.dart
@@ -5,7 +5,6 @@
library lock_file;
import 'dart:json' as json;
-import 'io.dart';
import 'package.dart';
import 'source_registry.dart';
import 'utils.dart';
@@ -22,19 +21,8 @@ class LockFile {
LockFile.empty()
: packages = <String, PackageId>{};
- /// Loads a lockfile from [filePath].
- factory LockFile.load(String filePath, SourceRegistry sources) {
- return LockFile._parse(filePath, readTextFile(filePath), sources);
- }
-
- /// Parses a lockfile whose text is [contents].
- factory LockFile.parse(String contents, SourceRegistry sources) {
- return LockFile._parse(null, contents, sources);
- }
-
/// Parses the lockfile whose text is [contents].
- static LockFile _parse(String filePath, String contents,
- SourceRegistry sources) {
+ factory LockFile.parse(String contents, SourceRegistry sources) {
var packages = <String, PackageId>{};
if (contents.trim() == '') return new LockFile.empty();
@@ -66,8 +54,7 @@ class LockFile {
throw new FormatException('Package $name is missing a description.');
}
var description = spec['description'];
- description = source.parseDescription(filePath, description,
- fromLockFile: true);
+ source.validateDescription(description, fromLockFile: true);
var id = new PackageId(name, source, version, description);
« no previous file with comments | « utils/pub/io.dart ('k') | utils/pub/path_source.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698