Description: avoid Windows-only crates Author: Jonas Smedegaard Forwarded: not-needed Last-Update: 2025-08-28 --- This patch header follows DEP-3: http://dep.debian.net/deps/dep3/ --- a/helix-stdx/Cargo.toml +++ b/helix-stdx/Cargo.toml @@ -24,9 +24,6 @@ serde = { version = "1.0", features = ["derive"] } percent-encoding = "2.3" -[target.'cfg(windows)'.dependencies] -windows-sys = { version = "0.61", features = ["Win32_Foundation", "Win32_Security", "Win32_Security_Authorization", "Win32_Storage_FileSystem", "Win32_System_Threading"] } - [target.'cfg(unix)'.dependencies] rustix = { version = "1.1", features = ["fs", "thread"] } --- a/helix-term/Cargo.toml +++ b/helix-term/Cargo.toml @@ -54,7 +54,7 @@ once_cell = "1.21" tokio = { version = "1", features = ["rt", "rt-multi-thread", "io-util", "io-std", "time", "process", "macros", "fs", "parking_lot"] } -tui = { path = "../helix-tui", package = "helix-tui", default-features = false, features = ["termina", "crossterm"] } +tui = { path = "../helix-tui", package = "helix-tui", default-features = false, features = ["termina"] } termina = { workspace = true, features = ["event-stream"] } signal-hook = "0.4" tokio-stream = "0.1" @@ -89,9 +89,6 @@ parking_lot.workspace = true -[target.'cfg(windows)'.dependencies] -crossterm = { version = "0.28", features = ["event-stream"] } - [target.'cfg(not(windows))'.dependencies] # https://github.com/vorner/signal-hook/issues/100 signal-hook-tokio = { version = "0.4", features = ["futures-v0_3"] } libc = "0.2.186" --- a/helix-tui/Cargo.toml +++ b/helix-tui/Cargo.toml @@ -12,7 +12,7 @@ homepage.workspace = true [features] -default = ["termina", "crossterm"] +default = ["termina"] [dependencies] helix-view = { path = "../helix-view", features = ["term"] } @@ -26,6 +26,3 @@ termini = "1.0" once_cell = "1.21" log = "~0.4" - -[target.'cfg(windows)'.dependencies] -crossterm = { version = "0.28", optional = true } --- a/helix-view/Cargo.toml +++ b/helix-view/Cargo.toml @@ -18,7 +18,7 @@ [features] default = [] -term = ["termina", "crossterm"] +term = ["termina"] unicode-lines = [] [dependencies] @@ -60,10 +60,6 @@ kstring = "2.0" -[target.'cfg(windows)'.dependencies] -clipboard-win = { version = "5.4", features = ["std"] } -crossterm = { version = "0.28", optional = true } - [target.'cfg(unix)'.dependencies] libc = "0.2" rustix = { version = "1.1", features = ["fs"] } --- a/Xtermina/Cargo.toml +++ b/Xtermina/Cargo.toml @@ -12,10 +12,6 @@ [features] default = [] event-stream = ["dep:futures-core"] -windows-legacy = [ - "windows-sys/Win32_UI_Input_KeyboardAndMouse", - "windows-sys/Win32_UI_WindowsAndMessaging", -] [dependencies] parking_lot = "0.12" @@ -35,22 +31,6 @@ "event", ] -[target.'cfg(windows)'.dependencies.windows-sys] -# TODO: this could probably be loosened. -version = ">=0.60" -default-features = false -# https://microsoft.github.io/windows-rs/features/#/0.59.0/search -features = [ - # Interaction with the legacy and modern console APIs. - "Win32_System_Console", - # Writing files (including console handles). - "Win32_Storage_FileSystem", - "Win32_System_IO", - # Polling for input. - "Win32_System_Threading", - "Win32_Security", -] - [[example]] name = "event-read" required-features = ["windows-legacy"]