feat(crossterm): allow multiple crossterm versions (#1841)

This commit introduces feature flags to make it possible for widget
library authors to depend on a specific version of crossterm without
causing version conflicts. This should make it easier for libraries and 
apps to update crossterm versions more easily.

The available feature flags are `crossterm_0_28` and `crossterm_0_29`.
By default, the latest version is enabled. If a multiple features are
enabled we choose the latest version. We will in general support at
least the last two major (0.x) versions of crossterm, and will only
remove versions in a major version bump.
This commit is contained in:
Josh McKinney
2025-08-17 12:43:18 -07:00
committed by GitHub
parent 86cd5292dd
commit 2d713d723d
13 changed files with 465 additions and 179 deletions

View File

@@ -158,6 +158,9 @@ jobs:
- uses: dtolnay/rust-toolchain@b3b07ba8b418998c39fb20f53e8b695cdcc8de1b # master
with:
toolchain: ${{ matrix.toolchain }}
- uses: taiki-e/install-action@f3a27926ea13d7be3ee2f4cbb925883cf9442b56 # v2
with:
tool: cargo-hack
- uses: Swatinem/rust-cache@98c8021b550208e191a6a3145459bfc9fb29c4c0 # v2
- run: cargo xtask check --all-features
@@ -232,6 +235,9 @@ jobs:
- uses: dtolnay/rust-toolchain@b3b07ba8b418998c39fb20f53e8b695cdcc8de1b # master
with:
toolchain: stable
- uses: taiki-e/install-action@f3a27926ea13d7be3ee2f4cbb925883cf9442b56 # v2
with:
tool: cargo-hack
- uses: Swatinem/rust-cache@98c8021b550208e191a6a3145459bfc9fb29c4c0 # v2
- run: cargo xtask test-docs
@@ -250,6 +256,9 @@ jobs:
- uses: dtolnay/rust-toolchain@b3b07ba8b418998c39fb20f53e8b695cdcc8de1b # master
with:
toolchain: stable
- uses: taiki-e/install-action@f3a27926ea13d7be3ee2f4cbb925883cf9442b56 # v2
with:
tool: cargo-hack
- uses: Swatinem/rust-cache@98c8021b550208e191a6a3145459bfc9fb29c4c0 # v2
- run: cargo xtask test-libs