Skip to content

Commit

Permalink
chore: adds event output when verbose
Browse files Browse the repository at this point in the history
  • Loading branch information
cristianoliveira committed Jun 12, 2023
1 parent 68eb0fe commit ff60feb
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/cli/watch.rs
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ impl Command for WatchCommand {

stdout::info("Watching...");
while let Ok(event) = rx.recv() {
stdout::verbose(&format!("Event {:?}", event), self.verbose);
if let DebouncedEvent::Create(path) = event {
let path_str = path.into_os_string().into_string().unwrap();
if let Some(rules) = self.watches.watch(&path_str) {
Expand Down
1 change: 1 addition & 0 deletions src/cli/watch_non_block.rs
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ impl Command for WatchNonBlockCommand {
loop {
match rx.try_recv() {
Ok(event) => {
stdout::verbose(&format!("Event {:?}", event), self.verbose);
if let DebouncedEvent::Create(path) = event {
let path_str = path.into_os_string().into_string().unwrap();

Expand Down

0 comments on commit ff60feb

Please sign in to comment.