Skip to content

✨ feat(run): support PATH lookup for external subcommands#1253

Merged
harehare merged 3 commits intomainfrom
feat/external-command-path-lookup
Feb 10, 2026
Merged

✨ feat(run): support PATH lookup for external subcommands#1253
harehare merged 3 commits intomainfrom
feat/external-command-path-lookup

Conversation

@harehare
Copy link
Copy Markdown
Owner

External subcommands (mq-) are now discovered via PATH using the which crate when not found in ~/.mq/bin, making it easier to install and use external subcommands system-wide.

Copilot AI review requested due to automatic review settings February 10, 2026 12:56
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds system PATH discovery for external mq-<name> subcommands (in addition to ~/.mq/bin) by integrating the which crate.

Changes:

  • Add which dependency to enable PATH lookup for external subcommands.
  • Update external-subcommand dispatch to accept a resolved command_path.
  • Prefer ~/.mq/bin/mq-<name> when present; otherwise try resolving mq-<name> via PATH.

Reviewed changes

Copilot reviewed 2 out of 3 changed files in this pull request and generated 2 comments.

File Description
crates/mq-run/src/cli.rs Adds PATH fallback (via which) and adjusts external command execution to take a resolved path.
crates/mq-run/Cargo.toml Introduces the which dependency required for PATH lookup.

Copilot AI review requested due to automatic review settings February 10, 2026 13:17
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 2 out of 3 changed files in this pull request and generated 4 comments.

External subcommands (mq-<name>) are now discovered via PATH using the
`which` crate when not found in ~/.mq/bin, making it easier to install
and use external subcommands system-wide.
@harehare harehare force-pushed the feat/external-command-path-lookup branch from bc0b6db to 40497cb Compare February 10, 2026 13:22
@harehare harehare merged commit 938101d into main Feb 10, 2026
8 checks passed
@harehare harehare deleted the feat/external-command-path-lookup branch February 10, 2026 14:03
cderv added a commit to cderv/r-bucket that referenced this pull request Feb 11, 2026
mq v0.5.14 now searches system PATH for mq-<name> executables
(harehare/mq#1253), so copying mq-tui into ~/.mq/bin/ is no
longer needed. Scoop's shim on PATH is sufficient.

Co-Authored-By: Claude Opus 4.6 <[email protected]>
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