-
-
Notifications
You must be signed in to change notification settings - Fork 769
chore(deps): bump usage-lib to 2.9.0 #7177
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR updates the usage-lib dependency to version 2.9.0 and adapts the codebase to handle a breaking API change where the default field in SpecArg and SpecFlag structs changed from Option<String> to Vec<String>.
- Wraps single default values in vectors using
.map(|s| vec![s])to match the new API - Updates flag default value access to use
.first()to extract the first element from the vector - Maintains backward compatibility by providing empty vectors as fallback
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- Update Cargo.lock to usage-lib 2.9.0 - Fix breaking API change: default field changed from Option<String> to Vec<String> in SpecArg and SpecFlag structs
- Variadic flags (var=#true) now return empty arrays instead of empty strings for their default values in the Tera usage context - Flag defaults are now properly used (instead of always returning empty values) - Enable previously disabled e2e tests for variadic flag join and defaults - Update test to use proper KDL syntax for multiple defaults
|
Ah, I have a different implementation at #7179 |
Hyperfine Performance
|
| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |
|---|---|---|---|---|
mise-2025.11.11 x -- echo |
19.0 ± 0.5 | 18.2 | 23.3 | 1.00 |
mise x -- echo |
19.1 ± 0.4 | 18.4 | 20.8 | 1.01 ± 0.03 |
mise env
| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |
|---|---|---|---|---|
mise-2025.11.11 env |
18.5 ± 0.4 | 17.8 | 19.8 | 1.00 |
mise env |
18.8 ± 0.5 | 17.8 | 22.5 | 1.02 ± 0.03 |
mise hook-env
| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |
|---|---|---|---|---|
mise-2025.11.11 hook-env |
18.4 ± 0.6 | 17.8 | 25.9 | 1.00 |
mise hook-env |
18.6 ± 0.4 | 17.9 | 20.3 | 1.01 ± 0.04 |
mise ls
| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |
|---|---|---|---|---|
mise-2025.11.11 ls |
15.9 ± 0.4 | 15.1 | 17.6 | 1.02 ± 0.03 |
mise ls |
15.5 ± 0.2 | 15.1 | 17.2 | 1.00 |
xtasks/test/perf
| Command | mise-2025.11.11 | mise | Variance |
|---|---|---|---|
| install (cached) | 106ms | 105ms | +0% |
| ls (cached) | 64ms | 64ms | +0% |
| bin-paths (cached) | 70ms | 71ms | -1% |
| task-ls (cached) | 430ms | 427ms | +0% |
- Variadic args with defaults now return arrays with default values - Non-variadic args with defaults now use the default value - Add e2e tests for args with defaults (single and variadic) - Add test for variadic flag with string default (single element) Co-Authored-By: Krut Patel <[email protected]>
### 🚀 Features - **(config)** add support for netrc by @RobotSupervisor in [#7164](#7164) - **(lock)** add resolve_lock_info to core backends for checksum fetching by @jdx in [#7180](#7180) - **(ruby)** Install ruby from a zip file over HTTPS by @KaanYT in [#7167](#7167) - **(tasks)** add `usage` args to Tera context in run scripts by @iamkroot in [#7041](#7041) ### 🐛 Bug Fixes - **(lock)** validate platform qualifiers when reading from lockfile by @jdx in [#7181](#7181) - **(task)** retry shebang scripts on ETXTBUSY by @iamkroot in [#7162](#7162) - **(ui)** remove duplicate 'mise' prefix in verbose footer output by @jdx in [#7174](#7174) ### 📦️ Dependency Updates - bump usage-lib to 2.9.0 by @jdx in [#7177](#7177) ### 📦 Registry - remove duplicated ubi and github backends from gping by @risu729 in [#7144](#7144) - disable bashly test (not working in CI) by @jdx in [#7173](#7173) - disable cfn-lint test (failing in CI) by @jdx in [#7176](#7176) ### Chore - add fd to mise.toml by @blampe in [#7178](#7178) ### New Contributors - @RobotSupervisor made their first contribution in [#7164](#7164) ## 📦 Aqua Registry Updates #### New Packages (2) - [`Kitware/CMake`](https://github.com/Kitware/CMake) - [`quarto-dev/quarto-cli`](https://github.com/quarto-dev/quarto-cli) #### Updated Packages (6) - [`apache/jena`](https://github.com/apache/jena) - [`apache/spark`](https://github.com/apache/spark) - [`danielfoehrKn/kubeswitch`](https://github.com/danielfoehrKn/kubeswitch) - [`danielfoehrKn/kubeswitch/switch-sh`](https://github.com/danielfoehrKn/kubeswitch/switch-sh) - [`evilmartians/lefthook`](https://github.com/evilmartians/lefthook) - [`updatecli/updatecli`](https://github.com/updatecli/updatecli)
Summary
defaultfield changed fromOption<String>toVec<String>inSpecArgandSpecFlagstructsTest plan
cargo check --all-featurespasses🤖 Generated with Claude Code
Note
Bumps usage-lib and updates parser, usage spec, and generated docs/man to use Vec defaults, with new e2e tests validating variadic args/flags and defaults behavior.
defaulthandling to arrays (Vec<String>) forargs/flagsinsrc/task/task_script_parser.rs.usagecontext with arrays for variadic args/flags (including defaults) and correct boolean/string defaults.mise.usage.kdl(e.g.,--type=infer,--localized-dir=.mise,--task=pre-commit|ci,--style=simple,--dir=bin,--mise-bin=mise,--http=http,--version=latest,--match-type=fuzzy,--on-busy-update=do-nothing,--stop-timeout=10s,--debounce=50ms,--emit-events-to=none,--wrap-process=group,--color=auto,--fs-events=create,remove,rename,modify,metadata).docs/cli/*andman/man1/mise.1to display these defaults.usagemap: variadic flag join, multi-default arrays, string default non-splitting, arg defaults, variadic arg defaults.Cargo.lock:usage-lib2.8.0 → 2.9.0.Written by Cursor Bugbot for commit 2f5f4c2. This will update automatically on new commits. Configure here.