Permalink
Browse files

cleanup cli options

  • Loading branch information...
1 parent aa96a52 commit 47aabc7290c85505f7656b25a659db467d540cb9 @cadorn cadorn committed Oct 18, 2012
Showing with 8 additions and 2 deletions.
  1. +3 −0 lib/commands/clone.js
  2. +5 −2 lib/commands/install.js
@@ -25,6 +25,9 @@ command.action(function (options) {
options.install = true;
}
+ // Update newInVersions but don't fetch latest remote info.
+ options.update = true;
+
options.locator = options.args[0];
options.help = true;
options.verbose = true;
@@ -10,9 +10,8 @@ command.help("Install package/program.");
command.arg(".../[package.json|program.json]").optional();
command.option("--dev").bool().help("Install dev dependencies as well.");
// NOTE: We don't default to 'now' on install as we want to be able to install 100% from cache in case network is down.
-command.option("-n", "--now").bool().help("Aggressively fetch latest remote info.");
+command.option("-n", "--now").bool().help("Aggressively fetch latest remote info (equivalent to `sm update`).");
command.option("-N", "--no-native-install").bool().help("Don't call native package installer (if applicable).");
-command.option("-c", "--cached").bool().help("Create from cache if exists. i.e. Don't check latest sources. Use `sm update` later.");
command.helpful();
command.action(function (options) {
@@ -22,6 +21,10 @@ command.action(function (options) {
return;
}
+ if (options.now) {
+ options.update = true;
+ }
+
PM.forProgramPath(basePath).then(function(pm) {
return pm.install(options);
}).then(function() {

0 comments on commit 47aabc7

Please sign in to comment.