1.9 KiB
1.9 KiB
ebitengine-tools
CI/CD templates for Ebitengine (Go) game projects, in the same spirit as tic80-tools.
example-makefile.make— project Makefile: local dev targets (build,wasm,export,watch,clean) plus the Woodpecker pipeline targets (ci-version,ci-export,ci-upload,ci-update).example-woodpecker.yaml— Woodpecker pipeline: version → export (Go,GOOS=js GOARCH=wasm) → upload (scp to the droparea) → update (calls the teletypegames/updateendpoint withplatform=ebitengine).example-tasks.json— VS Code.vscode/tasks.jsonwith the common dev tasks: Run (go run ., default build task,Cmd+Shift+B), Build & Run, Build WASM and Make build.web/index.html— the HTML shell downloaded bymake exportand packaged next to the.wasmbuild.
Usage in a game repo
- Copy
example-makefile.maketoMakefileand setPROJECT(the native binary is built tobin/$(PROJECT)). - Copy
example-woodpecker.yamlto.woodpecker.yamland add thedroparea_ssh_password/update_secret_keysecrets in Woodpecker. - Copy
example-tasks.jsonto.vscode/tasks.jsonand replace the binary name (ebitenginedemo) with$(PROJECT).
The pipeline uploads $(PROJECT)-$(VERSION).html.zip to the droparea,
then triggers
/update?platform=ebitengine&name=$(PROJECT)&version=$(VERSION).
Builder image
builder.Dockerfile bakes the pipeline's build-step dependencies
(Go + git/make/zip/curl) into
git.teletypegames.org/internal/ebitengine-builder, so the build step
no longer runs apk add on every run:
docker build --platform linux/amd64 -f builder.Dockerfile \
-t git.teletypegames.org/internal/ebitengine-builder:latest .
docker push git.teletypegames.org/internal/ebitengine-builder:latest
Detailed documentation lives on the wiki: /development/ebitengine.