Ungrouped command examples double the binary name (growthbook growthbook <cmd>)

Open Beginner friendly
#29 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
76/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Quiet
Tech stack
go
Domain
cli

Research direction

Start with .speakeasy/patches/internal/cli/getsdkpayload.go.patch and postcopytransform.go.patch, focusing on the two Example strings. Confirm how the ungrouped command examples are currently formed, then ensure each shows only one growthbook prefix for get-SDK-payload and post-copy-transform. The work is done when both examples no longer duplicate the binary name; retain the patches until the upstream generator is fixed.

Written by the indexing model from the issue text.

Description

bug custom

Bug

Top-level (ungrouped) commands generate examples that double the binary name:

growthbook growthbook get-SDK-payload --key <key>
growthbook growthbook post-copy-transform --visual-changeset-id <id> ...

Root cause (Speakeasy)

For operations with no command group, the example template prefixes both the app name and the binary name — both growthbook — yielding the doubled prefix.

Stopgap fix (retire when upstream is fixed)

.speakeasy/patches/internal/cli/getsdkpayload.go.patch and .../postcopytransform.go.patch: fix the two Example strings.

To retire: once the generator stops doubling the name for ungrouped ops, drop both patches. NOTE: any new ungrouped operation will reproduce the bug and need its own patch until the generator is fixed.

Refs

  • Introduced by #23
  • Upstream: file to speakeasy-api/speakeasy (example generation for ungrouped operations).
Dominant language
Go
Stars
1
Forks
0
Avg merge
1d 5h
Merged PRs (30d)
18

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from growthbook/cli

All issues in growthbook/cli

Similar issues

More Go issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.