| Index: utils/pub/entrypoint.dart
|
| diff --git a/utils/pub/entrypoint.dart b/utils/pub/entrypoint.dart
|
| index 6729381df8e05163dbafbc7b552a1a83e995aece..d3f79beca41923a4006129aa927716c7b5b4bbe4 100644
|
| --- a/utils/pub/entrypoint.dart
|
| +++ b/utils/pub/entrypoint.dart
|
| @@ -116,12 +116,28 @@ class Entrypoint {
|
| * package to its "package" directory, writing a new [LockFile]. Returns a
|
| * [Future] that completes when all dependencies are installed.
|
| */
|
| - Future updateDependencies() {
|
| + Future updateAllDependencies() {
|
| return resolveVersions(cache.sources, root, new LockFile.empty()).
|
| chain(_installDependencies);
|
| }
|
|
|
| /**
|
| + * Installs the latest available versions of [dependencies], while leaving
|
| + * other dependencies as specified by the [LockFile]. Returns a [Future] that
|
| + * completes when all dependencies are installed.
|
| + */
|
| + Future updateDependencies(List<String> dependencies) {
|
| + return _loadLockFile().chain((lockFile) {
|
| + for (var dependency in dependencies) {
|
| + // TODO(nweiz): How do we want to detect and handle unknown
|
| + // dependencies here?
|
| + lockFile.packages.remove(dependency);
|
| + }
|
| + return resolveVersions(cache.sources, root, lockFile);
|
| + }).chain(_installDependencies);
|
| + }
|
| +
|
| + /**
|
| * Installs all dependencies listed in [packageVersions] and writes a
|
| * [LockFile].
|
| */
|
|
|