| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 library pub.lock_file; | 5 library pub.lock_file; |
| 6 | 6 |
| 7 import 'dart:collection'; | |
| 8 | |
| 9 import 'package:yaml/yaml.dart'; | 7 import 'package:yaml/yaml.dart'; |
| 10 | 8 |
| 11 import 'io.dart'; | 9 import 'io.dart'; |
| 12 import 'log.dart' as log; | |
| 13 import 'package.dart'; | 10 import 'package.dart'; |
| 14 import 'source_registry.dart'; | 11 import 'source_registry.dart'; |
| 15 import 'utils.dart'; | 12 import 'utils.dart'; |
| 16 import 'version.dart'; | 13 import 'version.dart'; |
| 17 | 14 |
| 18 /// A parsed and validated `pubspec.lock` file. | 15 /// A parsed and validated `pubspec.lock` file. |
| 19 class LockFile { | 16 class LockFile { |
| 20 /// The packages this lockfile pins. | 17 /// The packages this lockfile pins. |
| 21 Map<String, PackageId> packages; | 18 Map<String, PackageId> packages; |
| 22 | 19 |
| (...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 98 }; | 95 }; |
| 99 }); | 96 }); |
| 100 | 97 |
| 101 return """ | 98 return """ |
| 102 # Generated by pub | 99 # Generated by pub |
| 103 # See http://pub.dartlang.org/doc/glossary.html#lockfile | 100 # See http://pub.dartlang.org/doc/glossary.html#lockfile |
| 104 ${yamlToString({'packages': data})} | 101 ${yamlToString({'packages': data})} |
| 105 """; | 102 """; |
| 106 } | 103 } |
| 107 } | 104 } |
| OLD | NEW |