Эх сурвалжийг харах

fix(cli): use terminal_size instead of term_size for Windows support (#3955)

Lucas Fernandes Nogueira 3 жил өмнө
parent
commit
f68af45a11

+ 0 - 11
tooling/cli/Cargo.lock

@@ -2733,7 +2733,6 @@ dependencies = [
  "tauri-bundler",
  "tauri-utils",
  "tempfile",
- "term_size",
  "terminal_size",
  "toml",
  "toml_edit",
@@ -2804,16 +2803,6 @@ dependencies = [
  "utf-8",
 ]
 
-[[package]]
-name = "term_size"
-version = "0.3.2"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "1e4129646ca0ed8f45d09b929036bafad5377103edd06e50bf574b353d2b08d9"
-dependencies = [
- "libc",
- "winapi 0.3.9",
-]
-
 [[package]]
 name = "termcolor"
 version = "1.1.3"

+ 0 - 1
tooling/cli/Cargo.toml

@@ -64,7 +64,6 @@ url = { version = "2.2", features = [ "serde" ] }
 os_pipe = "1"
 ignore = "0.4"
 ctrlc = "3.2"
-term_size = "0.3"
 
 [target."cfg(windows)".dependencies]
 encode_unicode = "0.3"

+ 2 - 2
tooling/cli/src/dev.rs

@@ -416,8 +416,8 @@ fn start_app(
   command
     .env(
       "CARGO_TERM_PROGRESS_WIDTH",
-      term_size::dimensions_stderr()
-        .map(|(w, _)| w)
+      terminal_size::terminal_size()
+        .map(|(w, _)| w.0)
         .unwrap_or(80)
         .to_string(),
     )