godot-export-ci
Installation
SKILL.md
Export and CI (4.7)
Run it: python scripts/export.py --list shows presets plus whether templates are installed. python scripts/export.py "Windows Desktop" [--debug|--pack|--patch] [--out path] exports headless and verifies the file. C# projects get built by the export.
Presets
export_presets.cfg(commit it) holds the presets. Secrets go to.godot/export_credentials.cfg(never commit.godot/). Create presets in the editor (Project → Export). A preset written by hand needsname,platform,runnable,export_filter,include_filter,exclude_filter,export_pathand a[preset.N.options]section.- Options per platform are queryable:
api_lookup.py EditorExportPlatformWindowslists everycodesign/*,application/*andbinary_format/*option with its default. The same works for...Android,...Web,...MacOS,...LinuxBSDand...IOS. - Feature tags: platform (
windows,android,web),debug/release,dedicated_server, plus custom tags per preset (demo,steam). Check them withOS.has_feature("steam"). Override project settings per tag (setting.tag=valuein the editor's "Override for"). - Resources: export all, selected scenes or resources with filters, or "Dedicated Server" (strips textures and audio data). Exclude
test/,*.mdand dev tools withexclude_filter. - Shader baker (4.5+):
shader_baker/enabled = trueper preset removes first-run shader hitches. It's slower to export. - Version:
application/config/versionis used for file and store versions unless the preset overrides it.
Templates
- They must match the editor exactly:
4.7.2.stablefor the standard editor,4.7.2.stable.monofor .NET. Location: Windows%APPDATA%\Godot\export_templates\<ver>\, Linux~/.local/share/godot/export_templates/<ver>/, macOS~/Library/Application Support/Godot/export_templates/<ver>/. - The 4.7 editor can download templates per platform: Editor → Manage Export Templates. In CI, download
Godot_v4.7.2-stable[_mono]_export_templates.tpz(a zip withtemplates/) from the GitHub release and unzip its contents into that folder. - A .NET editor exports only with .NET templates, even for GDScript-only projects.
export.pyreports missing templates with the exact path.
CLI
godot --headless --path P --export-release "<preset>" build/game.exe (also --export-debug, --export-pack out.pck|.zip, --export-patch out.pck --patches base.pck). Run --import first on fresh clones, which export.py does implicitly through the editor. The output folder must exist. Exit code 0 doesn't always mean success, so check that the artifact exists (export.py does).