officer 47e3983f7e rewrite asset paths baked into the page, including JSON-escaped ones
Gitea inlines a script naming its own worker:
'\/assets\/js\/eventsource.sharedworker.…js'. That is not an attribute and its
slashes are backslash-escaped, so neither the attribute rewrite nor appSubUrl
saw it. Unprefixed, the browser resolved it against the PLATFORM's origin, got
the SPA's index.html, and reported "Uncaught SyntaxError: Unexpected token '<'"
from a file that appeared to load — along with a dead SharedWorker and a
heatmap parsing HTML as JSON.

appSubUrl covers everything Gitea's code BUILDS at runtime. This covers what is
already in the page before that code runs.

Narrow on purpose, like dev-proxy's /_bun/ rule: a blanket rewrite of absolute
paths inside JavaScript corrupts strings that are not URLs. /assets/ is Gitea's
own asset root and specific enough to match safely.

The escaping has to match the string it lands in — \/api\/gitea\/_web, not
\\/api — or the JS stops parsing. Both forms are tested against a live sample.
2026-08-19 09:28:04 +00:00
2026-08-19 08:48:31 +00:00

Gitea

Your own Gitea inside Officer — repositories, issues and pull requests, rendered as the real thing rather than a copy of it.

What you get

Gitea's own web interface, in an Officer panel. Not a reimplementation: the actual application, proxied through Officer so it stays signed in, with an open in a new tab button for anything the frame handles badly.

Requirements

A Gitea instance Officer can reach.

Setup

Install the plugin, open /gitea, and set the instance URL and an API token in the connection panel. Then sign in to Gitea inside the frame, once — the frame shows your Gitea account, not the owner's.

The stored token is used only for the small things around the frame. Everything you see in it is your own session.

For agents

This plugin ships an affordance: use plain git for clone, fetch, pull and push; use tea for pull requests, issues, comments and releases. tea is logged in as you, with your permissions.

Permissions

One permission, gitea, grantable per role like any other app permission. Each account reaches its own Gitea identity.

S
Description
Gitea in Officer — repositories, issues and pull requests
Readme
2.2 MiB
Languages
TypeScript 100%