Skip to content

Commit

Permalink
uucore: turn ranges into a feature
Browse files Browse the repository at this point in the history
  • Loading branch information
cakebaker committed Sep 3, 2023
1 parent f8845cd commit 183d465
Show file tree
Hide file tree
Showing 7 changed files with 7 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/uu/cut/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ path = "src/cut.rs"

[dependencies]
clap = { workspace = true }
uucore = { workspace = true }
uucore = { workspace = true, features = ["ranges"] }
memchr = { workspace = true }
bstr = { workspace = true }
is-terminal = { workspace = true }
Expand Down
2 changes: 1 addition & 1 deletion src/uu/numfmt/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ path = "src/numfmt.rs"

[dependencies]
clap = { workspace = true }
uucore = { workspace = true }
uucore = { workspace = true, features = ["ranges"] }

[[bin]]
name = "numfmt"
Expand Down
1 change: 1 addition & 0 deletions src/uucore/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ mode = ["libc"]
perms = ["libc", "walkdir"]
pipes = []
process = ["libc"]
ranges = []
ringbuffer = []
signals = []
sum = [
Expand Down
2 changes: 2 additions & 0 deletions src/uucore/src/lib/features.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ pub mod fsext;
pub mod lines;
#[cfg(feature = "memo")]
pub mod memo;
#[cfg(feature = "ranges")]
pub mod ranges;
#[cfg(feature = "ringbuffer")]
pub mod ringbuffer;
#[cfg(feature = "sum")]
Expand Down
File renamed without changes.
3 changes: 2 additions & 1 deletion src/uucore/src/lib/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ pub use crate::mods::line_ending;
pub use crate::mods::os;
pub use crate::mods::panic;
pub use crate::mods::quoting_style;
pub use crate::mods::ranges;
pub use crate::mods::version_cmp;

// * string parsing modules
Expand All @@ -48,6 +47,8 @@ pub use crate::features::fsext;
pub use crate::features::lines;
#[cfg(feature = "memo")]
pub use crate::features::memo;
#[cfg(feature = "ranges")]
pub use crate::features::ranges;
#[cfg(feature = "ringbuffer")]
pub use crate::features::ringbuffer;
#[cfg(feature = "sum")]
Expand Down
1 change: 0 additions & 1 deletion src/uucore/src/lib/mods.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ pub mod error;
pub mod line_ending;
pub mod os;
pub mod panic;
pub mod ranges;
pub mod version_cmp;
// dir and vdir also need access to the quoting_style module
pub mod quoting_style;

0 comments on commit 183d465

Please sign in to comment.