ci: add Forgejo Actions build pipeline #1

Open
marcy wants to merge 40 commits from forgejo-build-pipeline into main
Owner

Summary

  • Add Forgejo Actions CI/CD workflow for building and publishing Pygmalion
  • Test job runs on every push with continue-on-error for alpha builds
  • Matrix build job creates self-contained executables for win-x64 and osx-x64
  • Upload job publishes packages to Forgejo registry on main branch only

Test Plan

  • Push to non-main branch: test and build jobs run, upload job skipped
  • Push to main branch: all jobs run, packages uploaded to registry
  • Check packages visible in repository's Packages section
## Summary - Add Forgejo Actions CI/CD workflow for building and publishing Pygmalion - Test job runs on every push with continue-on-error for alpha builds - Matrix build job creates self-contained executables for win-x64 and osx-x64 - Upload job publishes packages to Forgejo registry on main branch only ## Test Plan - [ ] Push to non-main branch: test and build jobs run, upload job skipped - [ ] Push to main branch: all jobs run, packages uploaded to registry - [ ] Check packages visible in repository's Packages section
Completed brainstorming session. Design includes:
- Form-based script editor replacing text area
- New quest editor panel with relationship tracking
- Consistent TOML serialization with semantic field ordering
- Cross-panel navigation for quest authoring workflow
- 6 implementation phases

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Round-trip test: SerializeQuest_Roundtrip_ProducesIdenticalOutput passes
- Confirms that re-serializing a quest produces identical TOML output
- All 6 Roundtrip tests pass
- Ensures consistent field ordering maintains round-trip semantics
The _orderedKeys field was populated but never read. Since Tomlyn's internal
implementation maintains insertion order automatically (as documented in the
Build() method comment), tracking keys manually serves no functional purpose.

- Removed _orderedKeys field declaration
- Removed all _orderedKeys.Add() calls from Add, AddIf, AddIfNotEmpty, AddIfNotNull methods
- Verified build succeeds with no new errors

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Important Issue: Add debug logging to empty catch block in ScriptEditorPanel when handling directory scanning errors (line 762-765)
- Minor Issue 1: Add test case for choice reference updates in UpdateNodeReferences to verify dialogue choices are properly updated when node IDs change
- Minor Issue 2: Implement action editor key renaming by tracking parameter key changes and updating the Params dictionary accordingly

All tests pass (545/545).
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Add Editor System to key systems documentation in both AGENTS.md and
CLAUDE.md. Update testing section to include dotnet test command now
that unit tests exist.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Completed brainstorming session. Design includes:
- Matrix build for Windows and macOS in parallel
- Test job with continue-on-failure for alpha builds
- Package upload to Forgejo registry (main branch only)
- 4 implementation phases

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Four-phase implementation plan:
- Phase 1: Workflow scaffolding with three job stubs
- Phase 2: Test job with continue-on-failure
- Phase 3: Matrix build for win-x64 and osx-x64
- Phase 4: Package upload to Forgejo registry (main only)

Includes:
- zip/curl installation for Docker containers
- Prerequisites for Forgejo secrets/variables
- Correct artifact download paths

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Three-job pipeline structure:
- test: runs after checkout
- build: matrix for win-x64 and osx-x64, depends on test
- upload: conditional on main branch, depends on build

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Restore dependencies before testing
- Run dotnet test with --no-restore for efficiency
- Set continue-on-error: true to allow alpha builds even with failing tests

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Publish self-contained executable for each platform
- Copy platform-specific fnalibs to publish output
- Create ZIP archive for distribution
- Upload as workflow artifact with 30-day retention

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Download artifacts from build job
- Compute version as YYYY-MM-DD-<short-sha>
- Upload to Forgejo generic packages via curl PUT
- Only runs on main branch pushes
- Uses FORGEJO_TOKEN secret and FORGEJO_API_URL variable

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
docs: update project context for forgejo-build-pipeline
Some checks failed
Build / test (push) Failing after 30s
Build / build (osx, osx-x64) (push) Has been skipped
Build / build (x64, win-x64) (push) Has been skipped
Build / upload (push) Has been skipped
f1d635a33e
Add CI/CD section documenting Forgejo Actions workflow with test, build,
and upload jobs. Update freshness dates.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
ci: install Node.js for GitHub Actions in container jobs
Some checks failed
Build / test (push) Successful in 1m5s
Build / build (osx, osx-x64) (push) Failing after 1m24s
Build / build (x64, win-x64) (push) Failing after 1m12s
Build / upload (push) Has been skipped
d963534858
The actions/checkout, actions/upload-artifact, and actions/download-artifact
actions require Node.js to run. The .NET SDK Docker image doesn't include
Node.js, so we need to install it before using these actions.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
ci: downgrade artifact actions to v3 for Forgejo compatibility
All checks were successful
Build / test (push) Successful in 1m2s
Build / build (osx, osx-x64) (push) Successful in 1m18s
Build / build (x64, win-x64) (push) Successful in 1m21s
Build / upload (push) Has been skipped
723d18eb3a
The v4 versions of upload-artifact and download-artifact use GitHub's
new artifact backend which is not supported on Forgejo/self-hosted runners.
Downgrade to v3 which uses the compatible artifact storage.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
ci: enable single-file publishing with FNA.dll excluded
All checks were successful
Build / test (push) Successful in 1m0s
Build / build (osx, osx-x64) (push) Successful in 2m13s
Build / build (x64, win-x64) (push) Successful in 1m23s
Build / upload (push) Has been skipped
a3872830c6
Per FNA distribution guidelines, enable PublishSingleFile=true for a
single executable output while excluding FNA.dll from bundling. This
allows developers and users to swap the FNA library for debugging or
modding purposes.

- Add ExcludeFromSingleFile to FNA ProjectReference in Engine.csproj
- Add -p:PublishSingleFile=true to dotnet publish in workflow

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
All checks were successful
Build / test (push) Successful in 1m0s
Build / build (osx, osx-x64) (push) Successful in 2m13s
Build / build (x64, win-x64) (push) Successful in 1m23s
Build / upload (push) Has been skipped
This pull request has changes conflicting with the target branch.
  • AGENTS.md
  • CLAUDE.md
  • src/Pygmalion.Engine.Tests/Unit/Editor/QuestRelationshipScannerTests.cs
  • src/Pygmalion.Engine/Editor/Panels/QuestEditorPanel.cs
  • src/Pygmalion.Engine/Editor/Panels/ScriptEditorPanel.cs
  • src/Pygmalion.Engine/Editor/QuestRelationshipScanner.cs
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin forgejo-build-pipeline:forgejo-build-pipeline
git switch forgejo-build-pipeline

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.

git switch main
git merge --no-ff forgejo-build-pipeline
git switch forgejo-build-pipeline
git rebase main
git switch main
git merge --ff-only forgejo-build-pipeline
git switch forgejo-build-pipeline
git rebase main
git switch main
git merge --no-ff forgejo-build-pipeline
git switch main
git merge --squash forgejo-build-pipeline
git switch main
git merge --ff-only forgejo-build-pipeline
git switch main
git merge forgejo-build-pipeline
git push origin main
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
infra.pink/pygmalion!1
No description provided.