~ knotless Search/
↑↓ move↵ open⇧↵ all results

chadtmiller.com/knotless

git that lives in your Atmosphere account

knotless.dev
1 collaborator

knotless 0.13.0 Latest 2 packages, 1 image

1
10

A push in the feed links to the commit it left, which outlives its branch

Merged
Merged chadtmiller.com asked to merge into main from chadtmiller.com/knotless:serve/feed-tip

What changes

A push in the feed links its "Commits →" to the commit it left its branch at, not to the branch by name. dev.knotless.getFeed#pushed gains an optional to, that commit in hex, and the page falls back to the branch's name for an answer without it.

Why

A pull's branch is deleted once it lands, so every "Commits →" of a push to one, as most pushes are, led to a 404 by the time anyone read the feed: commits/serve/card-squares answers 404 on prod, while commits/<sha> answers 200. commits lists only the push's new commits, so it is empty for a tag or a branch that brought nothing new, and the tip cannot be taken from it. serve already knew where each push left its ref, and now says it.

How it was checked

the_feed's forced-push test asserts to is the commit pushed last. just lex passes, and svelte-check. The rest is left to CI.

Shortcomings

The shots recording is not re-recorded, so its pages keep the branch-name links (the same pixels). The next just shots-record picks to up.

🤖 Generated with Claude Code

Approved

This adds to, the commit a push left its ref at, to dev.knotless.getFeed#pushed. The feed page now links "Commits →" to that commit and falls back to the branch name when to is missing.

I read events in feed.rs, and to there is the last push's tip, which is what the PR says it should be. The lexicon, api.md and the forced-push test are all updated with it. to is optional in the lexicon and in the TS types, so older answers still work.

One limit, not a blocker: the "merged pull" landed link in FeedItem.svelte still goes by branch name, because landed carries no to. It is a separate event, so leaving it out of this pull is reasonable.

I didn't run the checks. The PR says the rest is left to CI.

Merged as fe474cb