Skip to content

Commit

Permalink
[deps]: Update Rust crate inquire to 0.7.0 (#784)
Browse files Browse the repository at this point in the history
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
| [inquire](https://togithub.com/mikaelmello/inquire) | dependencies |
minor | `0.6.2` -> `0.7.0` |

---

### Release Notes

<details>
<summary>mikaelmello/inquire (inquire)</summary>

###
[`v0.7.5`](https://togithub.com/mikaelmello/inquire/blob/HEAD/CHANGELOG.md#075---2024-04-23)

[Compare
Source](https://togithub.com/mikaelmello/inquire/compare/v0.7.4...v0.7.5)

- Fix user-provided ANSI escape codes from being removed when rendering.
- Introduced on 0.7.0, this regression was making it impossible to have
colorised text inside the prompt.
- Now ANSI escape codes are properly emitted when rendering the prompt
in the terminal.

###
[`v0.7.4`](https://togithub.com/mikaelmello/inquire/blob/HEAD/CHANGELOG.md#074---2024-03-25)

[Compare
Source](https://togithub.com/mikaelmello/inquire/compare/v0.7.3...v0.7.4)

- Fix unexpected behaviors of `keep_filter` option in MultiSelect
prompts:
- Filter input is now correcly getting reset **only when** `keep_filter
== false`.
- When the filter input is reset, the list of options is now correctly
reset as well. Thanks
[@&#8203;Swivelgames](https://togithub.com/Swivelgames) for reporting
[#&#8203;238](https://togithub.com/mikaelmello/inquire/issues/238).

###
[`v0.7.3`](https://togithub.com/mikaelmello/inquire/blob/HEAD/CHANGELOG.md#073---2024-03-21)

[Compare
Source](https://togithub.com/mikaelmello/inquire/compare/v0.7.2...v0.7.3)

-   Fix cursor occasionally blinking in unexpected places.

###
[`v0.7.2`](https://togithub.com/mikaelmello/inquire/blob/HEAD/CHANGELOG.md#072---2024-03-17)

[Compare
Source](https://togithub.com/mikaelmello/inquire/compare/v0.7.1...v0.7.2)

- Pressing Ctrl+D now cancels the prompt. Thanks
[@&#8203;mikecvet](https://togithub.com/mikecvet) for the PR!
- Add support for `h` and `l` bindings when vim_mode is enabled on
MultiSelect prompts, clearing or selecting all options respectively.
Thanks [@&#8203;afh](https://togithub.com/afh) for the PR!
- Fix render issue
[#&#8203;233](https://togithub.com/mikaelmello/inquire/issues/233) where
cursor positioning at the end of a prompt was incorrect. Thanks
[@&#8203;msrd0](https://togithub.com/msrd0) and
[@&#8203;Sydonian](https://togithub.com/Sydonian) for reporting!

###
[`v0.7.1`](https://togithub.com/mikaelmello/inquire/blob/HEAD/CHANGELOG.md#071---2024-03-10)

[Compare
Source](https://togithub.com/mikaelmello/inquire/compare/v0.7.0...v0.7.1)

- Fix render issue
[#&#8203;228](https://togithub.com/mikaelmello/inquire/pull/228) when
using `console` crate as the terminal backend. Thanks
[@&#8203;maospr](https://togithub.com/maospr) for reporting.

###
[`v0.7.0`](https://togithub.com/mikaelmello/inquire/blob/HEAD/CHANGELOG.md#070---2024-02-24)

[Compare
Source](https://togithub.com/mikaelmello/inquire/compare/v0.6.2...v0.7.0)

##### Breaking Changes

- The Select and Multiselect Filter now scores input and is now expected
to return an `Option<i64>`, making it possible to order/rank the list of
options.
[#&#8203;176](https://togithub.com/mikaelmello/inquire/pull/176)
    `None`: Will not be displayed in the list of options.
`Some(score)`: score determines the order of options, higher score,
higher on the list of options.
- Improved user experience on Password prompts. When there is a
validation error, the input is cleared if the password is rendered using
the `Hidden` display mode, matching the user expectation of having to
write the password from scratch again. Thanks to
[@&#8203;CM-IV](https://togithub.com/CM-IV) for the questions on
[#&#8203;149](https://togithub.com/mikaelmello/inquire/issues/149)!
- Allow lifetime customization of RenderConfig.
[#&#8203;101](https://togithub.com/mikaelmello/inquire/pull/101). Thanks
to [@&#8203;arturfast](https://togithub.com/arturfast) for the
suggestion
[#&#8203;95](https://togithub.com/mikaelmello/inquire/issues/95).
- Implement fuzzy search as default on Select and MultiSelect prompts.
[#&#8203;176](https://togithub.com/mikaelmello/inquire/pull/176)
-   Revamped keybindings for DateSelect.

##### Features

- Add one-liner helpers for quick scripts.
[#&#8203;144](https://togithub.com/mikaelmello/inquire/pull/144).
- Add new option on MultiSelect prompts to set all options to be
selected by default. Thanks to
[@&#8203;conikeec](https://togithub.com/conikeec) for the suggestion
([#&#8203;151](https://togithub.com/mikaelmello/inquire/issues/151))!
- Add new option on Select/MultiSelect prompts allowing to reset
selection to the first item on filter-input changes.
[#&#8203;176](https://togithub.com/mikaelmello/inquire/pull/176)
-   Emacs-like keybindings added where applicable:
    -   Ctrl-p/Ctrl-n for up/down
    -   Ctrl-b/Ctrl-f for left/right
    -   Ctrl-j/Ctrl-g for enter/cancel
-   Vim keybindings are always supported in DateSelect prompts.
- Added 'with_starting_filter_input' to both Select and MultiSelect,
which allows for setting an initial value to the filter section of the
prompt.
- Added starting_input for CustomType.
[#&#8203;194](https://togithub.com/mikaelmello/inquire/pull/194)
- Added 'without_filtering' to both Select and MultiSelect, useful when
you want to simplify the UX if the filter does not add any value, such
as when the list is already short.
- Added 'with_answered_prompt_prefix' to RenderConfig to allow
customization of answered prompt prefix.
- Improved rendering, with optimizations on incremental rendering and
terminal resizing.

##### Fixes

-   Fixed typos in the code's comments.
- Fixed issue where inquire, using termion, would crash when receiving
piped inputs.

##### Dependency changes (some breaking)

-   Upgraded underlying `termion` crate from v1.5 to v2.0.
- Upgraded underlying `bitflags` from v1 to v2, which affects the
`Attributes` and `KeyModifiers` crates. If you use any of bitflag's
methods directly, you might be affected, refer to the [bitflags
changelog](https://togithub.com/bitflags/bitflags/releases/tag/2.0.0)
for more information.
- Removed `thiserror` dependency in favor of implementing `InquireError`
by hand.
[#&#8203;146](https://togithub.com/mikaelmello/inquire/issues/146)
-   Raised MSRV to 1.66 due to requirements in downstream dependencies.
-   MSRV is now explicitly set in the package definition.
- Replaced `lazy_static` with `once_cell` as `once_cell::sync::Lazy` is
being standardized and `lazy_static` is not actively maintained anymore.
- Added `fuzzy-matcher` as an optional dependency for fuzzy filtering in
Select and MultiSelect prompts
[#&#8203;176](https://togithub.com/mikaelmello/inquire/pull/176)

</details>

---

### Configuration

📅 **Schedule**: Branch creation - "every 2nd week starting on the 2 week
of the year before 4am on Monday" (UTC), Automerge - At any time (no
schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/bitwarden/sdk).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4zNTEuMiIsInVwZGF0ZWRJblZlciI6IjM3LjM1MS4yIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6W119-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
  • Loading branch information
renovate[bot] authored May 14, 2024
1 parent c59ce6c commit 8b0aa86
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 9 deletions.
33 changes: 26 additions & 7 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion crates/bitwarden-cli/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ keywords.workspace = true
[dependencies]
clap = { version = "4.5.4", features = ["derive"] }
color-eyre = "0.6.3"
inquire = "0.6.2"
inquire = "0.7.0"
supports-color = "3.0.0"

[lints]
Expand Down
2 changes: 1 addition & 1 deletion crates/bw/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ bitwarden-crypto = { workspace = true }
clap = { version = "4.5.4", features = ["derive", "env"] }
color-eyre = "0.6.3"
env_logger = "0.11.1"
inquire = "0.6.2"
inquire = "0.7.0"
log = "0.4.20"
tokio = { version = "1.36.0", features = ["rt-multi-thread", "macros"] }

Expand Down

0 comments on commit 8b0aa86

Please sign in to comment.