Add Forgejo compile and release workflows #2
Loading…
Reference in a new issue
No description provided.
Delete branch "add-forgejo-ci"
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?
Stacked on #1 — these workflows need
pyproject.tomlanduv.lock, so this targetsmodernize-packaging-and-fixes. Merge #1 first.Modelled on
games/engine:.forgejo/workflows/, dispatch-only triggers,actions/checkout@v4+actions/upload-artifact@v3, and the compile → release split where release finds the newest successful compile run via the Forgejo API and promotes its artifact.Runner choice
runs-on: alma10, notbryan.alma10is the instance's general-purpose Linux runner —containers/engine-builder-linux'sbuild-image.yamland both engine release workflows use it bare, andslopenstein'sbake-maps.yamluses it with a container.bryanonly ever appears alongside theengine-linux-builderimage, and there is no Python image in thecontainersorg.Rather than adding one, the job installs uv in-step and lets uv provision its own interpreter. That satisfies
requires-python = ">=3.12"without depending on what the runner's system Python happens to be.Version handling
compile.yamlreadscstool.__version__for the artifact name.release.yamlreads the version back out of the built wheel filename (cstool-1.0.7-py3-none-any.whl→v1.0.7), which ties the tag to the artifact actually being published rather than to whatever the release job checked out. The engine reads a rootVERSIONfile; cstool has none, and adding one would duplicate a valuepyproject.tomlalready resolves dynamically.Release assets are the wheel and sdist directly — both are already distributable archives, so the engine's tar.gz wrapper adds nothing here.
Verified locally
Every
compile.yamlstep was run against this branch:Both YAML files parse.
Worth deciding
pull_requestandpushtriggers tocompile.yamlwould make it actually gate merges. I kept the convention rather than deviating unasked.cstool ./silicon.yamlrun needs the ELSEPA distribution, which is not redistributable. Getting that into CI means baking it into a private image in thecontainersorg and settingELSEPA_DIR.release.yamlfilters onref=refs/heads/masterto match this repo's default branch (the engine usesmain).