Skip to content

Commit

Permalink
Remove str deunicode (nushell#13693)
Browse files Browse the repository at this point in the history
# Description
Closes nushell#13677

Remove the command `str deunicode`, as it has a narrow application, is
loosely defined by the data provided by the `deunicode` crate and thus a
stabilization liability post-1.0.

Furthermore the data to perform the look-up is quite substantial.

Removing the command and the `deunicode` dependency saves 0.9 MB of
binary data in release mode (~ 2% of total)

(checked via `cargo bloat --release` for a linux x86 build)


# User-Facing Changes
The `str deunicode` command recently added in nushell#13270 is gone
  • Loading branch information
sholderbach authored Aug 28, 2024
1 parent 7dda39a commit af76e11
Show file tree
Hide file tree
Showing 6 changed files with 0 additions and 110 deletions.
7 changes: 0 additions & 7 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 Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,6 @@ crossbeam-channel = "0.5.8"
crossterm = "0.27"
csv = "1.3"
ctrlc = "3.4"
deunicode = "1.6.0"
dialoguer = { default-features = false, version = "0.11" }
digest = { default-features = false, version = "0.10" }
dirs = "5.0"
Expand Down
1 change: 0 additions & 1 deletion crates/nu-command/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ chrono-humanize = { workspace = true }
chrono-tz = { workspace = true }
crossterm = { workspace = true }
csv = { workspace = true }
deunicode = { workspace = true }
dialoguer = { workspace = true, default-features = false, features = ["fuzzy-select"] }
digest = { workspace = true, default-features = false }
dtparse = { workspace = true }
Expand Down
1 change: 0 additions & 1 deletion crates/nu-command/src/default_context.rs
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,6 @@ pub fn add_shell_command_context(mut engine_state: EngineState) -> EngineState {
Str,
StrCapitalize,
StrContains,
StrDeunicode,
StrDistance,
StrDowncase,
StrEndswith,
Expand Down
98 changes: 0 additions & 98 deletions crates/nu-command/src/strings/str_/deunicode.rs

This file was deleted.

2 changes: 0 additions & 2 deletions crates/nu-command/src/strings/str_/mod.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
mod case;
mod contains;
mod deunicode;
mod distance;
mod ends_with;
mod expand;
Expand All @@ -16,7 +15,6 @@ mod trim;

pub use case::*;
pub use contains::SubCommand as StrContains;
pub use deunicode::SubCommand as StrDeunicode;
pub use distance::SubCommand as StrDistance;
pub use ends_with::SubCommand as StrEndswith;
pub use expand::SubCommand as StrExpand;
Expand Down

0 comments on commit af76e11

Please sign in to comment.