forked from trevato-apps/forge
feat(view): build pins #6
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "feat/build-pins"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Build pins: mark a commit as a build worth keeping, see the pins as a lineage, and optionally move the project demo to it.
What it is
A pin is a git ref,
refs/builds/<label>, holding an annotated tag: the commit, who pinned it and when, a note, and two trailers (Parent:when you name one,Source:for the pull, branch or commit it came from). Git is the whole record. Pinning runs no check and wakes no agent.The project demo is a third app environment beside production and previews. It serves one commit at
<slug>--demo.<domain>, with a copy of production's data, from the refrefs/demo. No ref, no demo. A push cannot moverefs/demo; only the forge does.How to use it
The Builds card on Branches draws every pin as a tree. A pin hangs under the parent you named, else under the nearest pin in its history (the ancestor pin that contains the most other pins). A fork's first pins hang under its parent repository's nearest pin, marked
owner/name:label. The branch graph marks pinned commits, and the pin the demo serves carries a demo badge that links to it.API
GET /api/v1/repos/:owner/:name/buildslists pins, newest first.POST /api/v1/repos/:owner/:name/buildswith{ label, sha, note?, parent?, source? }pins one (rw scope).PUT /api/v1/repos/:owner/:name/demowith{ sha }moves the demo;DELETEclears it.Rules
demois no longer a valid app slug, so<slug>--demoreads one way.Tests
New
test/build-pins.test.tsandtest/apps-demo.test.ts, both in the gate. Every gate file on this branch: 2312 pass, 4 fail; those four fail on main too (claim link host, outside spend, board, New forge door).Stacked on
feat/dev-forge.