Loading pipe-cli/src/commands/run/mod.rs +2 −2 Original line number Diff line number Diff line Loading @@ -2,7 +2,7 @@ use clap_verbosity_flag::Verbosity; use color_eyre::eyre::Report; use exitcode; use nanoid::nanoid; use pipe_lib::{get_conda_environment_name, Command, Config, EnvironmentValue, Label, ModuleLanguage, ModuleType, ModuleUri, Script}; use pipe_lib::{get_conda_environment_name, get_parent, Command, Config, EnvironmentValue, Label, ModuleLanguage, ModuleType, ModuleUri, Script}; use rayon::prelude::*; use std::convert::TryFrom; use std::env; Loading Loading @@ -189,7 +189,7 @@ pub fn run( cfg.modules.iter().for_each(|module| match &module.module_type { | ModuleType::Binary { ref uri, .. } => { let envs = EnvironmentValue::get_from_config(&cfg, Some(module.clone())); let parent = PathBuf::from(uri).parent().unwrap().to_string_lossy().to_string(); let parent = get_parent(PathBuf::from(uri)).to_string_lossy().to_string(); let working_dir = URI::try_from(parent.as_str()).unwrap().clone().path().to_string(); let loaded = Script::from_module(module.clone(), Some(PathBuf::from(working_dir.clone()))); let script = loaded.expand_arguments_from(envs).with_current_dir(working_dir); Loading pipe-lib/src/lib.rs +3 −3 Original line number Diff line number Diff line Loading @@ -612,7 +612,7 @@ impl Label { " RUN ▶ ".style(style) } pub fn using() -> Styled<&'static &'static str> { let style = Style::new().dimmed(); let style = Style::new().cyan(); "USING".style(style) } } Loading Loading @@ -997,8 +997,8 @@ impl Script { | Ok(result) => { if result.status.success() { let output = output; trace!("=> {} {:#?}", Label::output(), result); trace!("=> {} {:#?}", Label::output(), output); trace!("=> {} {:#?}", Label::output(), result.dimmed()); trace!("=> {} {:#?}", Label::output(), output.dimmed()); output } else { error!(script = self.to_string(), "=> {}", Label::fail()); Loading Loading
pipe-cli/src/commands/run/mod.rs +2 −2 Original line number Diff line number Diff line Loading @@ -2,7 +2,7 @@ use clap_verbosity_flag::Verbosity; use color_eyre::eyre::Report; use exitcode; use nanoid::nanoid; use pipe_lib::{get_conda_environment_name, Command, Config, EnvironmentValue, Label, ModuleLanguage, ModuleType, ModuleUri, Script}; use pipe_lib::{get_conda_environment_name, get_parent, Command, Config, EnvironmentValue, Label, ModuleLanguage, ModuleType, ModuleUri, Script}; use rayon::prelude::*; use std::convert::TryFrom; use std::env; Loading Loading @@ -189,7 +189,7 @@ pub fn run( cfg.modules.iter().for_each(|module| match &module.module_type { | ModuleType::Binary { ref uri, .. } => { let envs = EnvironmentValue::get_from_config(&cfg, Some(module.clone())); let parent = PathBuf::from(uri).parent().unwrap().to_string_lossy().to_string(); let parent = get_parent(PathBuf::from(uri)).to_string_lossy().to_string(); let working_dir = URI::try_from(parent.as_str()).unwrap().clone().path().to_string(); let loaded = Script::from_module(module.clone(), Some(PathBuf::from(working_dir.clone()))); let script = loaded.expand_arguments_from(envs).with_current_dir(working_dir); Loading
pipe-lib/src/lib.rs +3 −3 Original line number Diff line number Diff line Loading @@ -612,7 +612,7 @@ impl Label { " RUN ▶ ".style(style) } pub fn using() -> Styled<&'static &'static str> { let style = Style::new().dimmed(); let style = Style::new().cyan(); "USING".style(style) } } Loading Loading @@ -997,8 +997,8 @@ impl Script { | Ok(result) => { if result.status.success() { let output = output; trace!("=> {} {:#?}", Label::output(), result); trace!("=> {} {:#?}", Label::output(), output); trace!("=> {} {:#?}", Label::output(), result.dimmed()); trace!("=> {} {:#?}", Label::output(), output.dimmed()); output } else { error!(script = self.to_string(), "=> {}", Label::fail()); Loading