This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
This repository manages GitHub Actions workflows for building compilers used by Compiler Explorer (godbolt.org). It generates workflow YAML files from a central configuration file.
make deps # Install dependencies (Poetry + Python packages)
make build-yamls # Regenerate workflow YAML files from compilers.yaml
make test # Run tests
make pre-commit # Run all pre-commit hooks
make install-pre-commit # Install pre-commit hooks- compilers.yaml - Central configuration defining all compiler builds
- make_builds.py - Python script that reads compilers.yaml and generates:
- Individual workflow files in
.github/workflows/build-daily-*.yml - Status badges in
build-status.md
- Individual workflow files in
- pre-commit hook - Automatically runs
make build-yamlswhen Python/YAML files change
.github/actions/daily-build/action.yml- Reusable composite action for all builds.github/workflows/build-daily-*.yml- Auto-generated (DO NOT EDIT directly).github/workflows/ci.yml- CI for this repo itself
- Add entry to
compilers.yamlundercompilers.daily:- { image: <docker-image>, name: <unique-name>, args: <build-args> } # or with custom command: - { image: <docker-image>, name: <unique-name>, command: <script.sh>, args: <args> } # with repo activity checking (skips build if no commits in last N days): - { image: <docker-image>, name: <unique-name>, args: <args>, repos: ["https://github.com/owner/repo"] } # with specific branch: - { image: <docker-image>, name: <unique-name>, args: <args>, repos: ["https://github.com/owner/repo/tree/branch-name"] }
- Run
make build-yamls(or let pre-commit do it) - Also add entry in
remove_old_compilers.shin the infra repository
Compilers can specify a repos field with a list of GitHub repository URLs. If specified, a check-activity job runs first on ubuntu-latest to check for recent commits. The expensive daily-build job only runs if activity is found.
- If ANY repo has recent commits, the build runs
- If no
reposfield, builds always run (backwards compatible) - Branch can be specified in URL:
https://github.com/owner/repo/tree/branch-name - Stale days can be adjusted via
STALE_DAYSconstant inmake_builds.py(default: 7)
Builds run on self-hosted runners. The daily-build action:
- Pulls previous build revision from S3
- Runs Docker container with
compilerexplorer/<image>-builder - Uploads artifacts to
s3://compiler-explorer/opt/ - Logs build status to DynamoDB
compiler-buildstable
pre-run.sh- Records start timestamppost-run.sh- Records build result to DynamoDB