Repository navigation
tui: :repos lists your GitHub repos; enter runs onctl claude --repo on one - #1230
Merged
Merged
Conversation
…n one A `:repos` view in `onctl tui`, after boxctl's: the GitHub repositories gh's account can reach (`gh api user/repos`), newest push first, cached in ~/.onctl/repos.json (shown at once; GitHub asked again in the background when the cache is an hour old, or with R; never on the tick). Enter runs `onctl claude --repo owner/name` on the tui's provider as a child process, the way `s` runs `onctl ssh`; d describes, y is the JSON. `onctl claude --repo owner/name` is new too: no project here. A box of the selected provider named claude-<name> gets the repository's default branch cloned from GitHub onto a new onctl/<id> branch, and Claude starts in it. The same --repo again comes back to that box. A private repository needs --github store, since the clone runs before the attach that forwarding relies on. runClaude's tail (start or attach, --detach) is now startSession, shared with runRepo. Claude-Session: https://claude.ai/code/session_019xa1nemYLRH46Gz2Mj83fF
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1230 +/- ##
==========================================
+ Coverage 46.74% 47.07% +0.33%
==========================================
Files 75 77 +2
Lines 8786 9036 +250
==========================================
+ Hits 4107 4254 +147
- Misses 4679 4782 +103 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The onctl counterpart of boxctl's
:repos(boxctl PR #136), on onctl's own providers -- nothing here talks to boxctl.:reposinonctl tui: the GitHub repositories gh's account can reach (gh api user/repos: owned, collaborator, organization member), newest push first. Enter on a row runsonctl claude --repo owner/nameon the tui's provider as a child process, the waysrunsonctl ssh./filter,ddescribe (push access, and the command enter runs),yjson.~/.onctl/repos.json: opening the view shows the cache at once, asks GitHub in the background only when the cache is over an hour old, andRalways asks. Never listed on the 5s tick.Error:line), since the tui's redraw hides it.onctl claude --repo owner/name(new,-R): no project here. A box of the selected provider namedclaude-<name>gets the repository's default branch cloned from GitHub onto a newonctl/<id>branch, and Claude starts in it. The same--repoagain comes back to that box (the clone isn't made again). Works on boxes and on any provider's VM (onctl -p hetzner claude --repo ...). A private repository needs--github store, since the clone runs before the attach thatforwardrelies on; the clone error says so. Refuses--task,--own-box,--handoff,--project. Unlike boxctl's, no goals and no ephemeral box deletion -- the box is a Claude box like any other.runClaude's tail (start or attach,--detach) becamestartSession, shared withrunRepo.Tests
go test ./...passes,golangci-lintclean. New: the view's rows/sort/filter/describe/json, enter handing off and the VM keys doing nothing there, the cache (fresh: no fetch; tick: no fetch; R: fetch; stale: shown meanwhile and refetched; a failed fetch keeps the rows and flashes why), the done-message flash, the API page parser;parseRepo, the box name and branch, the clone script run for real against a local repo, the flag conflicts and the attach hint.gh api user/reposwas run once by hand to confirm the shape. Not exercised: an actualonctl claude --reporun against a box or VM.🤖 Generated with Claude Code
https://claude.ai/code/session_019xa1nemYLRH46Gz2Mj83fF