Skip to content

feat(discover): route the standalone docker-compose binary - #3653

Closed
dwin-gharibi wants to merge 1 commit into
rtk-ai:developfrom
dwin-gharibi:feat/docker-compose-hyphenated-rewrite
Closed

dwin-gharibi wants to merge 1 commit into
rtk-ai:developfrom
dwin-gharibi:feat/docker-compose-hyphenated-rewrite

Conversation

@dwin-gharibi

@dwin-gharibi dwin-gharibi commented Aug 23, 2026 •

Copy link
Copy Markdown

Closes #3652.

Summary

  • New rule routing docker-compose (ps|logs|build) to rtk docker compose …, the same filters
    the v2 subcommand spelling already reaches.
  • Scoped to the three subcommands that have filters. up, down and exec stay native — up
    and exec are long-running or interactive, and rtk captures rather than streams.

Test plan

  • cargo fmt --all && cargo clippy --all-targets && cargo test
  • Manual testing: rtk <command> output inspected

Unit tests (added)

src/discover/registry.rs, module docker_compose_hyphenated:

  • hyphenated_form_routes_to_the_same_filter — ps, logs, build, and ps -a, each landing
    on rtk docker compose ….
  • subcommand_form_still_rewrites — the v2 spelling is untouched.
  • unfiltered_compose_subcommands_are_left_alone — up, down, exec web sh return None.

Behavioural check (fake docker-compose on PATH)

The fake honours the --format "{{.Name}}\t{{.Image}}\t{{.Status}}\t{{.Ports}}" template rtk
passes, as the real binary does:

Command Preserved Size Exit
docker-compose ps all three services web, db, cache, and Exited state 205 B → 150 B (27% smaller) 0
docker-compose logs FATAL line unchanged 0

The docker rule covers docker compose ps/logs/build, the v2 subcommand
spelling. The standalone hyphenated binary -- still what a large share of
projects and CI scripts invoke -- matched nothing, so docker-compose ps ran
unfiltered while docker compose ps was compressed by the very same filter.

Scoped to the three subcommands that have filters. up, down and exec stay
native: they are long-running or interactive, and rtk captures rather than
streams.
Copilot AI lite review requested due to automatic review settings August 23, 2026 17:33

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@CLAassistant

CLAassistant commented Aug 23, 2026 •

Copy link
Copy Markdown

CLA assistant check
All committers have signed the CLA.

@rtk-release-bot

Copy link
Copy Markdown
Contributor

This pull request has been automatically marked as stale due to 90 days of inactivity. If this pull request is still relevant, please leave any comment (for example, "bump"), and we'll keep it open. Your contribution is very much appreciated — we're sorry we haven't been able to review it yet.

@rtk-release-bot

Copy link
Copy Markdown
Contributor

Closing this pull request after a prolonged period of inactivity. If this is still relevant, please ask for it to be reopened. Thank you!

@rtk-release-bot rtk-release-bot Bot closed this Nov 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

The standalone docker-compose binary is not routed, only docker compose

3 participants