From 63629a92e3f603dfd7e35770b722673613b64315 Mon Sep 17 00:00:00 2001 From: Dirkjan Ochtman Date: Mon, 8 Sep 2025 11:13:46 +0200 Subject: [PATCH 1/4] Fix lint warning for elided lifetimes --- src/ansi.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ansi.rs b/src/ansi.rs index a0abb980..d13d16e9 100644 --- a/src/ansi.rs +++ b/src/ansi.rs @@ -189,7 +189,7 @@ fn find_ansi_code_exclusive(it: &mut Peekable) -> Option<(usize, us /// Helper function to strip ansi codes. #[cfg(feature = "alloc")] -pub fn strip_ansi_codes(s: &str) -> Cow { +pub fn strip_ansi_codes(s: &str) -> Cow<'_, str> { let mut char_it = s.char_indices().peekable(); match find_ansi_code_exclusive(&mut char_it) { Some(_) => { From aa2cf023b6ae2580f82f5e85bda00ab2d696f18b Mon Sep 17 00:00:00 2001 From: Dirkjan Ochtman Date: Mon, 8 Sep 2025 11:15:09 +0200 Subject: [PATCH 2/4] Bump MSRV to 1.71 (for windows-sys 0.61) --- .github/workflows/ci.yml | 18 +++++++++--------- Cargo.toml | 2 +- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 12f0ac90..8ee0bdbd 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -6,17 +6,17 @@ on: branches: [main] jobs: build-msrv: - name: Build on MSRV (1.66) + name: Build on MSRV (1.71) strategy: fail-fast: false matrix: include: - os: ubuntu-latest target: x86_64-unknown-linux-gnu - rust: 1.66.0 + rust: 1.71.0 - os: windows-latest target: i686-pc-windows-msvc - rust: 1.66.0 + rust: 1.71.0 runs-on: ${{ matrix.os }} steps: - name: Install rust @@ -29,7 +29,7 @@ jobs: - name: Checkout uses: actions/checkout@v3 - name: MSRV dependencies - if: matrix.rust == '1.66.0' + if: matrix.rust == '1.71.0' run: make msrv-lock - name: Check env: @@ -47,16 +47,16 @@ jobs: rust: stable - os: ubuntu-latest target: x86_64-unknown-linux-gnu - rust: 1.66.0 + rust: 1.71.0 - os: ubuntu-latest target: i686-unknown-linux-gnu - rust: 1.66.0 + rust: 1.71.0 - os: windows-latest target: i686-pc-windows-msvc - rust: 1.66.0 + rust: 1.71.0 - os: windows-latest target: x86_64-pc-windows-msvc - rust: 1.66.0 + rust: 1.71.0 - os: ubuntu-latest target: x86_64-unknown-linux-gnu rust: stable @@ -80,7 +80,7 @@ jobs: sudo apt-get update sudo apt-get install gcc-multilib - name: MSRV dependencies - if: matrix.rust == '1.66.0' + if: matrix.rust == '1.71.0' run: make msrv-lock - name: Test env: diff --git a/Cargo.toml b/Cargo.toml index 3deb82eb..47711183 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -9,7 +9,7 @@ homepage = "https://github.com/console-rs/console" repository = "https://github.com/console-rs/console" documentation = "https://docs.rs/console" readme = "README.md" -rust-version = "1.66" +rust-version = "1.71" [features] default = ["unicode-width", "ansi-parsing", "std"] From 1b43b7a303167a06ca72fc95e3ba9e4059e842f7 Mon Sep 17 00:00:00 2001 From: Dirkjan Ochtman Date: Mon, 8 Sep 2025 11:16:13 +0200 Subject: [PATCH 3/4] Upgrade windows-sys to 0.61 --- Cargo.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Cargo.toml b/Cargo.toml index 47711183..246e8f4e 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -27,7 +27,7 @@ unicode-width = { version = "0.2", optional = true } encode_unicode = "1" [target.'cfg(windows)'.dependencies.windows-sys] -version = "0.60" +version = "0.61" features = [ "Win32_Foundation", "Win32_System_Console", From 1e95ed6eebe63e79c6bb1f9b60cb5b5be1719951 Mon Sep 17 00:00:00 2001 From: Dirkjan Ochtman Date: Mon, 8 Sep 2025 11:20:32 +0200 Subject: [PATCH 4/4] Bump version to 0.16.1 --- Cargo.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Cargo.toml b/Cargo.toml index 246e8f4e..814d362f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,7 +1,7 @@ [package] name = "console" description = "A terminal and console abstraction for Rust" -version = "0.16.0" +version = "0.16.1" keywords = ["cli", "terminal", "colors", "console", "ansi"] license = "MIT" edition = "2021"