From 61a037b65edde36d07c6d44402eb65ab3e1f8507 Mon Sep 17 00:00:00 2001 From: Ashley Michal Lewis Date: Wed, 6 May 2020 17:19:50 -0500 Subject: [PATCH] move util struct where it's used --- .../build/wranglerjs/guarded_command.rs} | 0 src/commands/build/wranglerjs/mod.rs | 6 ++++-- src/lib.rs | 1 - 3 files changed, 4 insertions(+), 3 deletions(-) rename src/{util.rs => commands/build/wranglerjs/guarded_command.rs} (100%) diff --git a/src/util.rs b/src/commands/build/wranglerjs/guarded_command.rs similarity index 100% rename from src/util.rs rename to src/commands/build/wranglerjs/guarded_command.rs diff --git a/src/commands/build/wranglerjs/mod.rs b/src/commands/build/wranglerjs/mod.rs index 17e33478b..754edd0fe 100644 --- a/src/commands/build/wranglerjs/mod.rs +++ b/src/commands/build/wranglerjs/mod.rs @@ -1,4 +1,5 @@ mod bundle; +mod guarded_command; pub mod output; pub use bundle::Bundle; @@ -25,7 +26,8 @@ use crate::install; use crate::settings::toml::Target; use crate::terminal::message; use crate::upload::package::Package; -use crate::util; + +use guarded_command::GuardedCommand; // Run the underlying {wranglerjs} executable. @@ -64,7 +66,7 @@ pub fn run_build_and_watch(target: &Target, tx: Option>) -> Result<() // Turbofish the result of the closure so we can use ? thread::spawn::<_, Result<(), failure::Error>>(move || { - let _command_guard = util::GuardedCommand::spawn(command); + let _command_guard = GuardedCommand::spawn(command); let (watcher_tx, watcher_rx) = channel(); let mut watcher = notify::watcher(watcher_tx, Duration::from_secs(1))?; diff --git a/src/lib.rs b/src/lib.rs index 1e88f9685..8c54a61d2 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -9,4 +9,3 @@ pub mod installer; pub mod settings; pub mod terminal; pub mod upload; -pub mod util;