Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Support external `vp-<command>` executables, as Git and Cargo do

オープン
#3,195 コメント 0 件 リアクション 0 件 担当者 1 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

@cpojer がすでに取り組んでいます。

2026年10月22日 から。

評価

この issue はまだ評価されていません。

説明

enhancement pending triage

Problem

Workspace tool authors cannot expose a command such as vp pr gen: the global
CLI rejects pr before the workspace's JavaScript implementation can run.
Today our workspace runs the same tool with vp exec vpp pr gen.

Reproduction

With an executable named vp-pr installed in the workspace's node_modules/.bin,
vp pr --help should be able to run that executable with --help. With Vite+
1.3.0 installed, the current command exits 2 with error: Command 'pr' not found.
Patching the local dist/bin.js dispatcher does not help: it is never reached.

Checked source

Inspected the official repository at commit
733b973ebe26f097ebe007cb079b2ee64b2f7217 in ~/repo-references/vite-plus:

  • main.rs:522
    calls try_parse_args_from before command execution.
  • main.rs:537
    handles InvalidSubcommand as an error/suggestion. Only the successful parse
    arm reaches run_command at line 583.
  • cli.rs:69
    declares the closed Commands enum. It has no external-subcommand arm.
  • cli.rs:1298
    calls clap's try_get_matches_from and Args::from_arg_matches.
  • cli.rs:1179
    already routes exec through the managed local executable path.

Proposal

Support Git/Cargo-style external subcommands: when no built-in matches foo,
resolve vp-foo using the same managed runtime and workspace executable
resolution as vp exec, then forward the remaining argv unchanged.

Built-ins retain precedence. Unknown names still fail with the existing useful
error when no executable exists. No implicit package download or install is
needed. Preserve cwd, -C, stdout/stderr, exit status, signals, --, and platform
executable/shim behavior. A locally installed extension should be explicitly
available in the workspace, not inferred from a matching package name.

This gives workspace extensions a natural command without modifying Vite+'s
built-in command set or maintaining an unreachable JavaScript dispatch patch.

Suggested acceptance cases

  • vp foo a --flag -- value executes vp-foo with exact argument boundaries.
  • Existing built-ins win over a same-name executable.
  • Workspace executable resolution and -C behave like vp exec.
  • Missing executable retains the unknown-command error; no download occurs.
  • Child exit code and termination signals propagate.
  • Unix executables and Windows executable shims both work.
主要言語
Rust
スター
6.3k
フォーク
283
平均マージ
1日 14時間
マージ済み PR(30日)
230

環境構築

Codespaces で開く

このプロジェクトの開発コンテナを、あなたの GitHub アカウントでブラウザ上に起動します。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

voidzero-dev/vite-plus のほかの issue

voidzero-dev/vite-plus の issue をすべて見る

似ている issue

Rust の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。