File tree Expand file tree Collapse file tree 11 files changed +47
-0
lines changed
Expand file tree Collapse file tree 11 files changed +47
-0
lines changed Original file line number Diff line number Diff line change 11# Changelog
22
3+ ## notify 9.0.0 (unreleased)
4+ - FEATURE: added support for the [ ` flume ` ] ( https://docs.rs/flume ) crate
5+
36## debouncer-full 0.6.0 (unreleased)
47- FEATURE: allow ` FileIdCache ` trait implementations to choose ownership of the returned file-ids
8+ - FEATURE: added support for the [ ` flume ` ] ( https://docs.rs/flume ) crate
9+
10+ ## debouncer-mini 0.7.0 (unreleased)
11+ - FEATURE: added support for the [ ` flume ` ] ( https://docs.rs/flume ) crate
512
613## file-id 0.2.3 (unreleased)
714- CHANGE: implement ` AsRef<FileId> ` for ` FileId `
Original file line number Diff line number Diff line change @@ -21,6 +21,7 @@ edition = "2021"
2121[workspace .dependencies ]
2222bitflags = " 2.7.0"
2323crossbeam-channel = " 0.5.0"
24+ flume = " 0.11.1"
2425deser-hjson = " 2.2.4"
2526env_logger = " 0.11.2"
2627file-id = { version = " 0.2.2" , path = " file-id" }
Original file line number Diff line number Diff line change @@ -17,6 +17,7 @@ default = ["macos_fsevent"]
1717serde = [" notify-types/serde" ]
1818web-time = [" notify-types/web-time" ]
1919crossbeam-channel = [" dep:crossbeam-channel" , " notify/crossbeam-channel" ]
20+ flume = [" dep:flume" , " notify/flume" ]
2021macos_fsevent = [" notify/macos_fsevent" ]
2122macos_kqueue = [" notify/macos_kqueue" ]
2223serialization-compat-6 = [" notify/serialization-compat-6" ]
@@ -25,6 +26,7 @@ serialization-compat-6 = ["notify/serialization-compat-6"]
2526notify.workspace = true
2627notify-types.workspace = true
2728crossbeam-channel = { workspace = true , optional = true }
29+ flume = { workspace = true , optional = true }
2830file-id.workspace = true
2931walkdir.workspace = true
3032log.workspace = true
Original file line number Diff line number Diff line change @@ -16,6 +16,8 @@ A debouncer for [notify] that is optimized for ease of use.
1616
1717- ` crossbeam-channel ` passed down to notify, off by default
1818
19+ - ` flume ` passed down to notify, off by default
20+
1921- ` serialization-compat-6 ` passed down to notify, off by default
2022
2123[ docs ] : https://docs.rs/notify-debouncer-full
Original file line number Diff line number Diff line change 5252//! - `serde` passed down to notify-types, off by default
5353//! - `web-time` passed down to notify-types, off by default
5454//! - `crossbeam-channel` passed down to notify, off by default
55+ //! - `flume` passed down to notify, off by default
5556//! - `macos_fsevent` passed down to notify, off by default
5657//! - `macos_kqueue` passed down to notify, off by default
5758//! - `serialization-compat-6` passed down to notify, off by default
@@ -132,6 +133,13 @@ impl DebounceEventHandler for crossbeam_channel::Sender<DebounceEventResult> {
132133 }
133134}
134135
136+ #[ cfg( feature = "flume" ) ]
137+ impl DebounceEventHandler for flume:: Sender < DebounceEventResult > {
138+ fn handle_event ( & mut self , event : DebounceEventResult ) {
139+ let _ = self . send ( event) ;
140+ }
141+ }
142+
135143impl DebounceEventHandler for std:: sync:: mpsc:: Sender < DebounceEventResult > {
136144 fn handle_event ( & mut self , event : DebounceEventResult ) {
137145 let _ = self . send ( event) ;
Original file line number Diff line number Diff line change @@ -16,6 +16,7 @@ repository.workspace = true
1616default = [" macos_fsevent" ]
1717serde = [" notify-types/serde" ]
1818crossbeam-channel = [" dep:crossbeam-channel" , " notify/crossbeam-channel" ]
19+ flume = [" dep:flume" , " notify/flume" ]
1920macos_fsevent = [" notify/macos_fsevent" ]
2021macos_kqueue = [" notify/macos_kqueue" ]
2122serialization-compat-6 = [" notify/serialization-compat-6" ]
@@ -24,5 +25,6 @@ serialization-compat-6 = ["notify/serialization-compat-6"]
2425notify.workspace = true
2526notify-types.workspace = true
2627crossbeam-channel = { workspace = true , optional = true }
28+ flume = { workspace = true , optional = true }
2729log.workspace = true
2830tempfile.workspace = true
Original file line number Diff line number Diff line change @@ -8,6 +8,8 @@ Tiny debouncer for [notify]. Filters incoming events and emits only one event pe
88
99- ` crossbeam-channel ` passed down to notify, off by default
1010
11+ - ` flume ` passed down to notify, off by default
12+
1113- ` serde ` for serde support of event types, off by default
1214
1315- ` serialization-compat-6 ` passed down to notify, off by default
Original file line number Diff line number Diff line change 4747//!
4848//! - `serde` passed down to notify-types, off by default
4949//! - `crossbeam-channel` passed down to notify, off by default
50+ //! - `flume` passed down to notify, off by default
5051//! - `macos_fsevent` passed down to notify, off by default
5152//! - `macos_kqueue` passed down to notify, off by default
5253//! - `serialization-compat-6` passed down to notify, off by default
@@ -161,6 +162,13 @@ impl DebounceEventHandler for crossbeam_channel::Sender<DebounceEventResult> {
161162 }
162163}
163164
165+ #[ cfg( feature = "flume" ) ]
166+ impl DebounceEventHandler for flume:: Sender < DebounceEventResult > {
167+ fn handle_event ( & mut self , event : DebounceEventResult ) {
168+ let _ = self . send ( event) ;
169+ }
170+ }
171+
164172impl DebounceEventHandler for std:: sync:: mpsc:: Sender < DebounceEventResult > {
165173 fn handle_event ( & mut self , event : DebounceEventResult ) {
166174 let _ = self . send ( event) ;
Original file line number Diff line number Diff line change @@ -27,6 +27,7 @@ serialization-compat-6 = ["notify-types/serialization-compat-6"]
2727[dependencies ]
2828notify-types.workspace = true
2929crossbeam-channel = { workspace = true , optional = true }
30+ flume = { workspace = true , optional = true }
3031filetime.workspace = true
3132libc.workspace = true
3233log.workspace = true
Original file line number Diff line number Diff line change @@ -262,6 +262,13 @@ impl EventHandler for crossbeam_channel::Sender<Result<Event>> {
262262 }
263263}
264264
265+ #[ cfg( feature = "flume" ) ]
266+ impl EventHandler for flume:: Sender < Result < Event > > {
267+ fn handle_event ( & mut self , event : Result < Event > ) {
268+ let _ = self . send ( event) ;
269+ }
270+ }
271+
265272impl EventHandler for std:: sync:: mpsc:: Sender < Result < Event > > {
266273 fn handle_event ( & mut self , event : Result < Event > ) {
267274 let _ = self . send ( event) ;
You can’t perform that action at this time.
0 commit comments