See code, README and branches #98

Closed
opened 2026-10-09 11:25:05 -05:00 by deadstyle · 5 comments
Owner

Problem

lazyforge shows PRs, issues and runs, but not the repo itself. The next logical features are to see code, read the README, and see branches.

## Problem lazyforge shows PRs, issues and runs, but not the repo itself. The next logical features are to see code, read the README, and see branches.
Author
Owner

🤖 Parking this on a product question. docs/design.md has five boxes per repo and no place for the repo's own content, and the ticket has no acceptance criteria. Three decisions change what gets built:

1. Where do code, README and branches live?

  1. New boxes [6] Code, [7] Branches; README as the first tab of Code. Matches the box model, but the jump keys grow to seven and the box column gets taller. Cost: largest change.
  2. README shows in the right-hand preview when a repo is selected in the repo list; [6] Branches only. Reading the README costs no keystrokes. Code browsing waits for a later ticket.
  3. One new box [6] Repo with tabs README · Files · Branches. Least layout change, one jump key.

2. How deep is "see code"?

  1. File tree plus read-only file viewer (scrollable, o opens in browser). Cost: about two MRs.
  2. Tree only; o opens the file in the browser. Smallest, but you can't read a file in the terminal.

3. What does a branch row show? Proposed: name, default-branch marker, last commit message and age, ahead/behind the default branch, and whether it has an open PR. Details tab: the commit list. Read-only in v1 (no create/delete).

Recommendation: option 3 for layout, option 1 for depth, branches as proposed. One box keeps the keymap stable while adding all three features. Delivery would be one MR per feature (README, branches, files).

Reply with your picks, or "go with the recommendation", and the next session will split and deliver.

🤖 Parking this on a product question. `docs/design.md` has five boxes per repo and no place for the repo's own content, and the ticket has no acceptance criteria. Three decisions change what gets built: **1. Where do code, README and branches live?** 1. **New boxes `[6]` Code, `[7]` Branches; README as the first tab of Code.** Matches the box model, but the jump keys grow to seven and the box column gets taller. Cost: largest change. 2. **README shows in the right-hand preview when a repo is selected in the repo list; `[6]` Branches only.** Reading the README costs no keystrokes. Code browsing waits for a later ticket. 3. **One new box `[6]` Repo with tabs README · Files · Branches.** Least layout change, one jump key. **2. How deep is "see code"?** 1. **File tree plus read-only file viewer** (scrollable, `o` opens in browser). Cost: about two MRs. 2. **Tree only; `o` opens the file in the browser.** Smallest, but you can't read a file in the terminal. **3. What does a branch row show?** Proposed: name, default-branch marker, last commit message and age, ahead/behind the default branch, and whether it has an open PR. Details tab: the commit list. Read-only in v1 (no create/delete). **Recommendation:** option 3 for layout, option 1 for depth, branches as proposed. One box keeps the keymap stable while adding all three features. Delivery would be one MR per feature (README, branches, files). Reply with your picks, or "go with the recommendation", and the next session will split and deliver.
Author
Owner

🤖 PM answered: go with the recommendation (one box [6] Repo with README · Files · Branches tabs, read-only). Files uses Yazi-style navigation: h/l go up/into directories, j/k move, the right column previews the selected file or folder. Splitting into one MR per tab; the sub-tickets are linked below.

🤖 PM answered: go with the recommendation (one box [6] Repo with README · Files · Branches tabs, read-only). Files uses Yazi-style navigation: h/l go up/into directories, j/k move, the right column previews the selected file or folder. Splitting into one MR per tab; the sub-tickets are linked below.
Author
Owner

🤖 Split into #104 (box [6] + README), #105 (Branches), #106 (Files, Yazi-style). Delivering in that order; #98 closes when all three merge.

🤖 Split into #104 (box [6] + README), #105 (Branches), #106 (Files, Yazi-style). Delivering in that order; #98 closes when all three merge.
Author
Owner

🤖 PM decisions since the split, for whoever delivers #104, #105 and #106:

  • No ahead/behind column on the Branches tab (#105). It costs one extra API call per branch and the PM doesn't want it. #105's body is updated; the "blank rather than wrong" criterion is gone.
  • Default branch only on Files (#106). Switching branches is a separate ticket, #107, which will reuse the Files mechanics. Nothing for #104–#106 to build for it.
  • The Branches tab still lists every branch (name, default marker, last commit and age, open-PR flag).
  • Releases (#103) is a separate ticket: list releases, show notes.

Gaps an independent plan check found in a draft plan for #104 (unimplemented plan, not code). Worth checking against the branch:

  1. internal/ui/renovate.go also calls syncText (syncStarDetails), so changing its tab clamp has to cover that file; on ★ Renovate set the tab to 0.
  2. A forge that doesn't implement README reading must not set a status-bar error on every repo selection. Treat ErrUnsupported as "No README"; other errors (unauthorized, rate limited) show as for other kinds.
  3. docs/architecture.md needs the new optional interface and a README row in the API mapping table.
  4. Box [6] always shows the repo name row, even before the README loads; the README tab shows "Loading…". In boxes.go, switches using default: for runs would index runs for a repo box. Make them explicit cases.
  5. The accent colour should follow the box kind, not its position, or [6] changes colour between repos with and without runs.
  6. Existing UI tests that assert message counts, shift-tab from the first box, or the 1-5 hint strings change (model_test.go and helpers_test.go).
  7. Gitea: escape the README file name in the second request (spaces, non-ASCII); symlinked READMEs show "No README".
🤖 PM decisions since the split, for whoever delivers #104, #105 and #106: - **No ahead/behind column** on the Branches tab (#105). It costs one extra API call per branch and the PM doesn't want it. #105's body is updated; the "blank rather than wrong" criterion is gone. - **Default branch only on Files** (#106). Switching branches is a separate ticket, #107, which will reuse the Files mechanics. Nothing for #104–#106 to build for it. - The Branches tab still lists every branch (name, default marker, last commit and age, open-PR flag). - Releases (#103) is a separate ticket: list releases, show notes. Gaps an independent plan check found in a draft plan for #104 (unimplemented plan, not code). Worth checking against the branch: 1. `internal/ui/renovate.go` also calls `syncText` (`syncStarDetails`), so changing its tab clamp has to cover that file; on ★ Renovate set the tab to 0. 2. A forge that doesn't implement README reading must not set a status-bar error on every repo selection. Treat `ErrUnsupported` as "No README"; other errors (unauthorized, rate limited) show as for other kinds. 3. `docs/architecture.md` needs the new optional interface and a README row in the API mapping table. 4. Box [6] always shows the repo name row, even before the README loads; the README tab shows "Loading…". In `boxes.go`, switches using `default:` for runs would index runs for a repo box. Make them explicit cases. 5. The accent colour should follow the box kind, not its position, or [6] changes colour between repos with and without runs. 6. Existing UI tests that assert message counts, shift-tab from the first box, or the `1-5` hint strings change (model_test.go and helpers_test.go). 7. Gitea: escape the README file name in the second request (spaces, non-ASCII); symlinked READMEs show "No README".
Author
Owner

🤖 all three parts merged: #104 (PR #109), #105 (PR #110), #106 (PR #111)

🤖 all three parts merged: #104 (PR #109), #105 (PR #110), #106 (PR #111)
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
deadstyle/lazyforge#98
No description provided.