diff options
Diffstat (limited to 'bin/domain/imag-timetrack/src/shell.rs')
-rw-r--r-- | bin/domain/imag-timetrack/src/shell.rs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/bin/domain/imag-timetrack/src/shell.rs b/bin/domain/imag-timetrack/src/shell.rs index 5a888d8b..f4dde8d9 100644 --- a/bin/domain/imag-timetrack/src/shell.rs +++ b/bin/domain/imag-timetrack/src/shell.rs @@ -21,9 +21,9 @@ use std::env; use std::process::Command; use filters::filter::Filter; -use failure::Fallible as Result; -use failure::err_msg; -use failure::Error; +use anyhow::Result; + +use anyhow::Error; use resiter::Filter as RFilter; use resiter::AndThen; @@ -60,10 +60,10 @@ pub fn shell(rt: &Runtime) -> Result<()> { .map(mkshell) .map_err(|e| match e { env::VarError::NotPresent => { - err_msg("No $SHELL variable in environment, cannot work!") + anyhow!("No $SHELL variable in environment, cannot work!") }, env::VarError::NotUnicode(_) => { - err_msg("SHELL variable is not unicode, cannot work!") + anyhow!("SHELL variable is not unicode, cannot work!") } }) } @@ -75,7 +75,7 @@ pub fn shell(rt: &Runtime) -> Result<()> { } if !shellcmd.status()?.success() { - return Err(format_err!("Failed to execute {:?}", shellcmd)) + return Err(anyhow!("Failed to execute {:?}", shellcmd)) } let stop = ::chrono::offset::Local::now().naive_local(); let filter = has_one_of_tags(&tags); |