Skip to content

Add completion spec: Vite+ (vp) - #427

Merged
vikvang merged 1 commit into
warpdotdev:mainfrom
krishs0404:vp-completion-spec
Dec 5, 2026
Merged

vikvang merged 1 commit into
warpdotdev:mainfrom
krishs0404:vp-completion-spec

Conversation

@krishs0404

@krishs0404 krishs0404 commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

Closes #284.

Adds a completion spec for vp (Vite+, v1.6.0).

Spec (json/vp.json)

  • Covers create, migrate, dev, build, test (with its run/watch/dev/related/bench/list subcommands), lint, fmt/format, check, pack, run, exec, preview, cache, config, hooks, staged, toolchain, and the package-manager commands install/i, add, remove/rm/uninstall, update/up, dedupe, outdated, why/explain, link/ln, unlink, dlx, info/view, and pm with its subcommands.
  • Options were taken from each command's vp <command> --help output, not from docs.
  • upgrade and env are not included. They only exist in the global vp CLI and error out in the local one.

Generators (src/generators/vp.rs)

  • vp_tasks_generator (vp run): runs pwd -P; vp run --json and suggests package#task for every task in the workspace, plus the bare task name for tasks of the package the user is currently in.
  • vp_workspace_packages_generator (--filter, exec --resume-from): suggests workspace package names from the same vp run --json output.
  • dependencies_generator is reused for remove, update, outdated and why.
  • The npm registry search generator is reused for add, install, dlx and info. It is now pub(super) in npm.rs so vp.rs can use it.

Validation

  • script/presubmit passes: JSON formatting, cargo fmt, Clippy with warnings denied, and 182 tests (0 failures), including the checks that every spec deserializes and every referenced generator name exists.
  • Unit tests for both generators cover running inside a package, at the workspace root, a sibling directory sharing a path prefix (a vs a-extra), and empty/invalid output.

Manual UI verification
Verified in a locally rebuilt Warp on macOS with the local PR checkout and the WGPU renderer. The test workspace contains a root package and two workspace packages; testing was performed from packages/a with Vite+ 1.6.0 on PATH.

  • vp run <Tab>: task dropdown includes qualified workspace tasks and the current package's bare task names.
  • vp run --filter <Tab>: dropdown includes @m/a, @m/b, and root.
  • vp add rea<Tab>: dropdown shows live npm registry search results.
  • vp remove <Tab>: dropdown includes is-odd and left-pad.
  • vp run b<Tab> completes to vp run build.

No tasks or package changes were executed during UI verification. Local build overrides remain uncommitted.

Task dropdown

Task dropdown

Workspace packages

Workspace packages

npm registry search

npm registry search

Installed dependencies

Installed dependencies

Task completion accepted

Task completion accepted

🤖 Generated with Claude Code

Adds a completion spec for the vp CLI covering its subcommands and options,
with generators for vp run tasks (bare and package#task forms) and --filter
workspace packages, both driven by vp run --json. Package management
commands reuse the existing dependency and npm registry search generators.

Closes warpdotdev#284

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@cla-bot

cla-bot Bot commented Nov 16, 2026

Copy link
Copy Markdown

Thank you for your pull request and welcome to our community. We require contributors to sign our Contributor License Agreement, and we don't seem to have the users @krishs0404 on file. In order for us to review and merge your code, each contributor must visit https://cla.warp.dev to read and agree to our CLA. Once you have done so, please comment @cla-bot check to trigger another check.

@krishs0404

Copy link
Copy Markdown
Contributor Author

@cla-bot check

@cla-bot

cla-bot Bot commented Nov 16, 2026

Copy link
Copy Markdown

Thank you for your pull request and welcome to our community. We require contributors to sign our Contributor License Agreement, and we don't seem to have the users @krishs0404 on file. In order for us to review and merge your code, each contributor must visit https://cla.warp.dev to read and agree to our CLA. Once you have done so, please comment @cla-bot check to trigger another check.

@cla-bot

cla-bot Bot commented Nov 16, 2026

Copy link
Copy Markdown

The cla-bot has been summoned, and re-checked this pull request!

@krishs0404

Copy link
Copy Markdown
Contributor Author

@cla-bot check

@cla-bot cla-bot Bot added the cla-signed label Nov 16, 2026
@cla-bot

cla-bot Bot commented Nov 16, 2026

Copy link
Copy Markdown

The cla-bot has been summoned, and re-checked this pull request!

@krishs0404
krishs0404 marked this pull request as ready for review November 16, 2026 05:46
@vikvang
vikvang merged commit 08dcff2 into warpdotdev:main Dec 5, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add completion spec for vp (Vite+)

2 participants