Home

boring / v2

publicBoring-Software-Inc/v2
Overview Code History Branches Pull requestsIssuesInsights Campfire Docs
main
HomeOverview Code PRsIssues

feat(web): view on {forge} button, and stop assuming every run is github

2 months ago

ef79ba5
Authored
grim8/23/2026, 8:42:26 AM
run-view.ts resolved the repo with a hardcoded "github". An open-git run
therefore matched NO repo row, and the page quietly rendered a lesser version
of itself even for the account that owns it: no org slug, no repo name, no
re-run, and custom rules shown as bare generated refs instead of their names.
It read as a public run to its own owner. The forge now comes from the repo
row, via findRepoForge.

The button sits left of copy markdown and wears the forge's own mark, so a
maintainer with both forges connected sees where a run came from without
reading the label. It renders nothing when there is no change request or no
repo row, because a dead link is worse than no link.

changeRequestUrl lives in contracts because the path differs per forge
(/pull/ on github, /pulls/ on open-git) and was about to be rebuilt at every
call site. The origin is passed in, since a self-hosted instance moves and
contracts reads no environment.

subjectUrl stays on the public view. That view only renders for a repo that is
not private, so the link reveals nothing the viewer could not already open.

Verified against a real open-git run: forge resolves opengit, the repo row is
found, and the url is https://open-git.com/boring/playground/pulls/36

Parentaa91db6

7 files changed
  • apps/web/src/components/runs/run-page.tsx+29−0
  • apps/web/src/lib/run-access.test.ts+2−0
  • apps/web/src/lib/run-markdown.test.ts+2−0
  • apps/web/src/lib/runs.functions.ts+10−1
  • apps/web/src/lib/server/run-view.ts+24−8
  • packages/contracts/src/forges.test.ts+42−0
  • packages/contracts/src/forges.ts+38−0