Skip to content

Commit

Permalink
fix(core): canonicalize watch event paths on all linux distros (#19848)
Browse files Browse the repository at this point in the history
Co-authored-by: Jason Jean <[email protected]>
  • Loading branch information
Cammisuli and FrozenPandaz authored Oct 25, 2023
1 parent 900c1c9 commit a7e0abd
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 16 deletions.
10 changes: 0 additions & 10 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion packages/nx/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ ignore = '0.4'
ignore-files = "1.3.0"
itertools = "0.10.5"
once_cell = "1.18.0"
os_type = "2.6.0"
parking_lot = { version = "0.12.1", features = ["send_guard"] }
napi = { version = '2.12.6', default-features = false, features = [
'anyhow',
Expand Down
6 changes: 1 addition & 5 deletions packages/nx/src/native/watch/utils.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
use ignore::WalkBuilder;
use ignore_files::IgnoreFile;
use once_cell::sync::Lazy;
use os_type::{OSInformation, OSType};
use std::{fs, path::PathBuf};
use tracing::trace;
use watchexec_events::{Event, Tag};
Expand Down Expand Up @@ -56,10 +54,8 @@ pub(super) fn get_ignore_files<T: AsRef<str>>(root: T) -> Vec<IgnoreFile> {
// .collect()
// }

static OS_PLATFORM: Lazy<OSInformation> = Lazy::new(os_type::current_platform);

pub(super) fn transform_event(watch_event: &Event) -> Option<Event> {
if OS_PLATFORM.os_type == OSType::Debian || OS_PLATFORM.os_type == OSType::Arch {
if cfg!(linux) {
let tags = watch_event
.tags
.clone()
Expand Down

0 comments on commit a7e0abd

Please sign in to comment.