Squelch dead code warnings on non-Linux platforms (aka macOS)
This commit is contained in:
parent
0201f5c320
commit
ab754ac2e3
3 changed files with 6 additions and 1 deletions
|
@ -1,10 +1,12 @@
|
|||
pub mod build;
|
||||
pub mod apply;
|
||||
pub mod eval;
|
||||
pub mod apply_local;
|
||||
pub mod upload_keys;
|
||||
pub mod exec;
|
||||
pub mod nix_info;
|
||||
|
||||
#[cfg(target_os = "linux")]
|
||||
pub mod apply_local;
|
||||
|
||||
#[cfg(debug_assertions)]
|
||||
pub mod test_progress;
|
||||
|
|
|
@ -248,6 +248,7 @@ impl Hive {
|
|||
}
|
||||
|
||||
/// Retrieve deployment info for a single node.
|
||||
#[cfg_attr(not(target_os = "linux"), allow(dead_code))]
|
||||
pub async fn deployment_info_single(&self, node: &NodeName) -> ColmenaResult<Option<NodeConfig>> {
|
||||
let expr = format!("hive.nodes.\"{}\".config.deployment or null", node.as_str());
|
||||
self.nix_instantiate(&expr).eval_with_builders().await?
|
||||
|
|
|
@ -153,6 +153,8 @@ impl Deref for NodeName {
|
|||
|
||||
impl NodeConfig {
|
||||
pub fn tags(&self) -> &[String] { &self.tags }
|
||||
|
||||
#[cfg_attr(not(target_os = "linux"), allow(dead_code))]
|
||||
pub fn allows_local_deployment(&self) -> bool { self.allow_local_deployment }
|
||||
|
||||
pub fn build_on_target(&self) -> bool { self.build_on_target }
|
||||
|
|
Loading…
Reference in a new issue