feat: run on Forgejo Actions as well as GitHub Actions #1
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/forgejo-support"
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?
Makes the action usable from Forgejo Actions, not only GitHub Actions.
Verified end to end on this instance: run 5 posts the comment above using the
automatic workflow token, with no extra secret.
Forgejo Runner already exposes GitHub-compatible event variables, so the action
reached the right runner; what it got wrong was every URL it built.
github.com; they now come fromGITHUB_SERVER_URLvia the action context.GITHUB_RUN_ID. On Forgejo that is a globaldatabase id (3516 for run 5 here, which 404s); run pages are addressed by the
repository-scoped index in
GITHUB_RUN_NUMBER.so those comments stay visible instead of failing the run.
Artifacts cannot work on Forgejo today.
@actions/artifact6.2 and later send amime_typefield inCreateArtifact; Forgejo'sCreateArtifactRequestprotobufdefines fields 1-5 only and its handler unmarshals without
DiscardUnknown, so itanswers HTTP 500
Error decode request body. That proto has not changed since itwas ported from Gitea in March 2024, and there is no issue open for it. Pinning
back to
@actions/artifact6.1 is not an option either, becauseskipArchive—which keeps the HTML viewer artifact from being double-zipped — arrived in the
same 6.2 release.
So full mode now treats the upload as a warning rather than a failed run; the PR
comment carries the diff regardless.
diff-onlyandcomment-onlypass resultsbetween jobs as artifacts and stay GitHub-only until Forgejo accepts the field.
.forgejo/workflows/test-nix-diff-action.ymlexercises the action here. Adding italso stops Forgejo from picking up
.github/workflows, whoseruns-on: ubuntu-latestjobs had been failing on this instance.
Nix Diff
Compare changes
devShell
Attribute:
devShells.x86_64-linux.defaultDiff Output
Generated by nix-diff-action using dix
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.