feat(apps): rc apps apple setup on the guided rail - #140
Conversation
DX-997 Refit apps apple + auth + setup onto the tier; document + enforce
Once the pilot on |
9c5c7c5 to
bfdf6f1
Compare
bfdf6f1 to
2582ec1
Compare
2582ec1 to
813404d
Compare
813404d to
07aabbe
Compare
370f995 to
978af86
Compare
fire-at-will
left a comment
There was a problem hiding this comment.
A few questions, but looks good otherwise!
| existingVendor = extras.AppStoreVendorNumber() | ||
| } | ||
| if !checkOnly { | ||
| fl := tui.NewFlow(rt.Out.Stderr(), !rt.CanPrompt(), rt.Out.NoColor()) |
There was a problem hiding this comment.
Again, does this flow ignore --quiet?
There was a problem hiding this comment.
Yep — same fix; the guided Flow now honors --quiet.
| if im.cancelled { | ||
| return "", ErrPromptCancelled | ||
| } | ||
| return strings.TrimSpace(im.ti.Value()), nil |
There was a problem hiding this comment.
Should we be trimming passwords here? If, for some reason, my password start/ended with a space, that would make this unusable for me. That said, it's gotta be rare for spaces to be in passwords
There was a problem hiding this comment.
Fixed — Password no longer trims, so leading/trailing spaces are preserved. (Input still trims, which is fine for IDs/URLs.)
| } | ||
|
|
||
| fl := tui.NewFlow(os.Stderr, !rt.CanPrompt(), rt.Out.NoColor()) | ||
| fl := tui.NewFlow(rt.Out.Stderr(), !rt.CanPrompt(), rt.Out.NoColor()) |
There was a problem hiding this comment.
Same --quiet fix applied here too.
Refit apps apple setup/check onto the tui.Flow rail — intro, step headers, rail prompts (email, masked password, 2FA, team), receipts, and an outro — matching rc setup google. Adds Flow.Password (masked rail input) and routes guided output through the Renderer's writer (Renderer.Stderr) so it's captured in tests. Snapshot updated. Note: the live Apple 2FA path is not testable here. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
978af86 to
63c5ec9
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 63c5ec9. Configure here.
| existingVendor = extras.AppStoreVendorNumber() | ||
| } | ||
| if !checkOnly { | ||
| fl := tui.NewFlow(rt.Out.Stderr(), !rt.CanPrompt(), rt.Out.NoColor(), rt.Globals.Quiet) |
There was a problem hiding this comment.
Flow ignores JSON silence contract
Medium Severity
tui.NewFlow is only passed rt.Globals.Quiet, so under --json (without --quiet) the guided rail still writes Intro/Step/Say/Receipt chatter to stderr. The rest of this command still uses rt.Out.*, which suppresses on json || quiet, so --json previously produced clean stderr and now leaks plain Flow narration before the JSON envelope. Apple setup/check are JSON-scripted paths; this breaks that contract.
Reviewed by Cursor Bugbot for commit 63c5ec9. Configure here.


Moves
rc apps apple setuponto the same guided rail asrc setup google, so both setup flows look and feel identical.Note
Medium Risk
Touches the interactive Apple credential and 2FA path and stderr/stdout split, but core setup logic and JSON contracts are largely preserved with test/snapshot updates.
Overview
rc apps apple setupandchecknow use the sametui.Flowguided rail asrc setup google, replacingoutputtitles/plans/cards and separatehuhforms withIntro/Step/Item/Receipt/Outronarration.Interactive Apple sign-in moves onto the rail:
fl.Confirm,fl.Input, newfl.Password(masked entry, bullet receipt),fl.Selectfor team and 2FA, plus shorter privacy copy inline.decideAppleKeytakes aFlowand uses rail confirms. Humancheckresults are shown on the rail instead ofRenderCard;--jsonstill emits structured data on stdout (including early return for check).output.Renderer.Stderr()wires guided flows to the renderer’s stderr (tests andsetup googleusert.Out.Stderr()instead ofos.Stderr). Snapshots and one test assert guided text on stderr, keeping stdout data-only under--json.Reviewed by Cursor Bugbot for commit 63c5ec9. Bugbot is set up for automated code reviews on this repo. Configure here.