Repository navigation
Description
Epic. Build Forgejo (Codeberg / self-hosted Forgejo / Gitea) CI support as a thin dialect of the github lexicon, plus a github→forgejo compare/migration path. Scope below is grounded in a direct read of the github and gitlab lexicons.
Why Forgejo (research)
The 2026 GitHub exodus — driven by the Copilot training-by-default deadline (April 24 2026), reliability outages, and Copilot nagware — flows overwhelmingly to Codeberg/Forgejo, not GitLab. Verified-completed moves (BookStack, Zig, Gentoo) all landed on Codeberg. "moving to Codeberg" far outnumbers "migrate to GitLab" in GitHub issue search. Forgejo is the engine behind Codeberg, so one package covers Codeberg + self-hosted Forgejo + Gitea. (Full research + verified candidate reckoning lives in local ~/Documents/research/gitlab/.)
Key finding from reading the lexicons
Forgejo Actions YAML is GitHub Actions YAML. The github serializer (lexicons/github/src/serializer.ts) already emits the exact shape Forgejo runs (on:/jobs:/steps:, kebab-case keys, trigger map, multi-file via SerializerResult.files). So Forgejo needs no codegen and no own entity model — it reuses the github lexicon's generated entities. Only the dialect differs:
- output dir
.forgejo/workflows/(alias.gitea/workflows/) - ignored keys
permissions,continue-on-error(drop + warn) - runner labels/images differ
uses:refs don't resolve from a marketplace
This is far cheaper than gitlab, which needed a full separate schema, snake_case serializer, !reference intrinsic, and stage inference.
Architecture (the LexiconPlugin slots to fill)
name, serializer, lintRules/postSynthChecks, intrinsics, initTemplates/detectTemplate, LSP, import, codegen lifecycle, mcpTools/mcpResources, migrationSource(from), skills — same contract as github/src/plugin.ts and gitlab/src/plugin.ts. Reuse the migration model (gitlab/src/migrate/from-github/) and the security-fate engine (security.ts) — but github→forgejo is a thin transform (same language), and its value is the compare (what Forgejo drops), not a heavy transpiler.
Decisions (resolved)
- Thin dialect reusing github entities — not a standalone codegen'd lexicon. ✅
- Lead with compare/lint, not the transpiler — github→forgejo YAML is near-identical, so the differentiated value is "what Forgejo silently drops". ✅
- Runner labels: default with per-project override. ✅
- Cover Gitea for free via the
.gitea/workflowsalias. ✅
Plan (smallest valuable first)
- Forgejo P1: serializer dialect + build emits .forgejo/workflows (spike) #339 — P1 serializer dialect +
chant buildemits.forgejo/workflows/(drop ignored keys w/ warnings, runner-label default+override). Spike. - Forgejo P2: uses: action-ref resolver + unmapped-ref report #340 — P2
uses:action-ref resolver + unmapped-ref report. - Forgejo P3: migrationSource(github) + forgejo:compare (security-fate) #341 — P3
migrationSource("github")+forgejo:compare(security-fate; surfaces droppedpermissions/continue-on-error). Lead value. - Forgejo P4: context tools + lint + templates/skills/docs #342 — P4
forgejo:*context tools + lint deltas + templates/skills/docs.
Caveats
Pre-release, no customers — signal-driven, not demand-driven. Validate after P1/P3 before investing in the full P4 surface. Most projects this serves land on Codeberg, which is exactly why this exists.
Activity
lex00 commentedon Jun 15, 2026
All four phases shipped and merged to main — epic complete.
.forgejo/workflows/, dropspermissions/continue-on-errorwith warnings, maps runner labels.uses:action-ref resolver:actions/*underforgejo.actionsRoot,docker/*pinned to GitHub, unmapped refs reported.migrationSource("github")+forgejo:compare: the security-fate compare (translated/approximated/needs-review/lost). The lead value.forgejo:*context tools, WFJ010/011 lint checks,chant-forgejoskill, docs.@intentius/chant-lexicon-forgejoships as a thin dialect of the github lexicon — one package covers Codeberg, self-hosted Forgejo, and Gitea. Validated end-to-end (chant build→.forgejo/workflows/,chant migrate --to forgejo --validate). Per the epic's gate, P1+P3 delivered the differentiated value before P4 rounded out parity.