[PR Feedback] Reformat for readability
Turns out a bunch of these poorly-formatted comments were outdated.
@@ -2,8 +2,8 @@ use crate::{error::{Error,
Result},
PRODUCT,
VERSION};
-use habitat_common::{self,
- command::package::install::{InstallHookMode,
+use habitat_common::{command::package::install::{self as install_cmd,
+ InstallHookMode,
InstallMode,
InstallSource,
LocalPackageUsage},
@@ -34,22 +34,8 @@ pub fn install<T>(ui: &mut T,
Ok(v) => Some(v),
Err(_) => None,
};
-
- habitat_common::command::package::install::start(ui,
+ install_cmd::start(ui,
url,
- // We currently need this to be an option due
- // to how
- // the depot
- // client is written. Anything that calls the
- // current
- // function, though, should always have a
- // channel. We
- // should
- // push this "Option-ness" as far down the
- // stack as we
- // can,
- // with the ultimate goal of eliminating it
- // altogether.
channel,
install_source,
PRODUCT,
@@ -57,19 +43,11 @@ pub fn install<T>(ui: &mut T,
fs_root_path,
&fs::cache_artifact_path(None::<String>),
auth_token.as_ref().map(String::as_str),
- // TODO fn: pass through and enable offline
- // install
- // mode
&InstallMode::default(),
- // TODO (CM): pass through and enable
- // ignore-local
- // mode
&LocalPackageUsage::default(),
// Install hooks are run when the supervisor
- // loads the
- // package
- // in add_service so it is repetitive to run
- // them here
+ // loads the package in add_service so it is
+ // repetitive to run them here
InstallHookMode::Ignore).map_err(Error::from)
}
