Skip to content

feat(cli): add --min-dep-age alias#35914

Merged
nathanwhit merged 1 commit into
denoland:mainfrom
nathanwhit:codex/min-dep-age-alias
Jul 9, 2026
Merged

feat(cli): add --min-dep-age alias#35914
nathanwhit merged 1 commit into
denoland:mainfrom
nathanwhit:codex/min-dep-age-alias

Conversation

@nathanwhit

Copy link
Copy Markdown
Member

Summary

  • accept --min-dep-age as an alias for --minimum-dependency-age
  • include the alias in minimum dependency age policy hints
  • cover alias parsing and the updated user-facing hint

Why

The shorter spelling is already used by the embedded CLI parser, but the main
Deno CLI only accepted the full --minimum-dependency-age spelling. This makes
the short form available consistently and ensures users can discover it when a
dependency is blocked by the age policy.

Validation

  • cargo test -p deno --lib args::flags::tests::minimum_dependency_age_alias
  • cargo build -p deno
  • cargo test -p integration_tests add_npm_minimum_dependency_age_no_matching_shows_hint -- --nocapture
  • cargo test -p specs_tests --test specs -- npmrc_min_release_age
  • ./tools/format.js --check cli/args/flags.rs cli/lib.rs tests/integration/pm_tests.rs tests/specs/npm/npmrc_min_release_age/install.out

@nathanwhit
nathanwhit marked this pull request as ready for review July 9, 2026 18:45
@nathanwhit
nathanwhit enabled auto-merge (squash) July 9, 2026 18:57
@nathanwhit
nathanwhit merged commit c3d9d44 into denoland:main Jul 9, 2026
172 checks passed
bartlomieju pushed a commit that referenced this pull request Jul 15, 2026
## Summary

- accept `--min-dep-age` as an alias for `--minimum-dependency-age`
- include the alias in minimum dependency age policy hints
- cover alias parsing and the updated user-facing hint

## Why

The shorter spelling is already used by the embedded CLI parser, but the
main
Deno CLI only accepted the full `--minimum-dependency-age` spelling.
This makes
the short form available consistently and ensures users can discover it
when a
dependency is blocked by the age policy.

## Validation

- `cargo test -p deno --lib
args::flags::tests::minimum_dependency_age_alias`
- `cargo build -p deno`
- `cargo test -p integration_tests
add_npm_minimum_dependency_age_no_matching_shows_hint -- --nocapture`
- `cargo test -p specs_tests --test specs -- npmrc_min_release_age`
- `./tools/format.js --check cli/args/flags.rs cli/lib.rs
tests/integration/pm_tests.rs
tests/specs/npm/npmrc_min_release_age/install.out`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants