An empty firebreak_public_base_url only works while the person filling in
the wizard happens to be browsing the same origin Forgejo redirects back
to, so it can look fine during local setup and still be wrong in
production. It also leaves share URLs relative, since there is no
externally resolvable origin to build them from.
The setup page already derived the request's base URL to display the OAuth
callback hint, but persisted "" instead, so the field and the hint could
disagree. Pass the derived value through as the field's value and mark the
input required, dropping the hint that told users to leave it blank on
localhost.
Expose GET /links/repositories/{repo}/commits, resolving {owner}
server-side from the session's linked Forgejo identity like the sibling
branches route.
Take the ref as a query parameter instead of a path segment: branch names
contain slashes (docs/readme, feature/learn-public-links), which a single
path param cannot capture without a path converter. As a query param,
`ref` may also default to main.
Dropping the path default and declaring `repo` were both required for the
module to import: FastAPI asserts that path parameters have no defaults,
and an undeclared path param raised NameError at call time.