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

Unified Diff: lib/src/command/downgrade.dart

Issue 2250643003: Add a --[no]-packages-dir flag. (Closed) Base URL: git@github.com:dart-lang/pub.git@master
Patch Set: Created 4 years, 4 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
Index: lib/src/command/downgrade.dart
diff --git a/lib/src/command/downgrade.dart b/lib/src/command/downgrade.dart
index fd70963158ab54a7426c038ac798d540bf9d662c..c9d2f7dacdb17f3d624e5df001d86baa895a48f4 100644
--- a/lib/src/command/downgrade.dart
+++ b/lib/src/command/downgrade.dart
@@ -24,12 +24,19 @@ class DowngradeCommand extends PubCommand {
argParser.addFlag('dry-run', abbr: 'n', negatable: false,
help: "Report what dependencies would change but don't change any.");
+
+ argParser.addFlag('packages-dir',
+ negatable: true, defaultsTo: true,
+ help: "Generate a packages/ directory when installing packages.");
}
Future run() async {
var dryRun = argResults['dry-run'];
await entrypoint.acquireDependencies(SolveType.DOWNGRADE,
- useLatest: argResults.rest, dryRun: dryRun);
+ useLatest: argResults.rest,
+ dryRun: dryRun,
+ packagesDir: argResults['packages-dir']);
+
if (isOffline) {
log.warning("Warning: Downgrading when offline may not update you to "
"the oldest versions of your dependencies.");
« no previous file with comments | « lib/src/command.dart ('k') | lib/src/command/get.dart » ('j') | lib/src/entrypoint.dart » ('J')

Powered by Google App Engine
This is Rietveld 408576698