scripts/README_GH_ACTIONS.md
This directory contains gen_gh_actions.py, a script to generate GitHub Actions CI workflows from the same configuration logic used for Travis CI.
The script can generate workflows for different platforms:
# Generate Linux CI workflow (default)
./scripts/gen_gh_actions.py linux > .github/workflows/linux-ci.yml
# Generate macOS CI workflow
./scripts/gen_gh_actions.py macos > .github/workflows/macos-ci.yml
# Generate Windows CI workflow
./scripts/gen_gh_actions.py windows > .github/workflows/windows-ci.yml
# Generate FreeBSD CI workflow
./scripts/gen_gh_actions.py freebsd > .github/workflows/freebsd-ci.yml
# Generate combined workflow with all platforms
./scripts/gen_gh_actions.py all > .github/workflows/ci-all.yml
linux-ci.yml)ubuntu-latest (x86_64)
ubuntu-24.04-arm (aarch64)
Total: 110 configurations
macos-ci.yml)macos-15-intel (x86_64)
macos-latest (arm64)
Total: 21 configurations
windows-ci.yml)windows-latest (x86_64)
Total: 10 configurations
freebsd-ci.yml)ubuntu-latest
vmactions/freebsd-vm@v1gmake (GNU Make) instead of BSD makeTotal: 16 configurations
Each workflow includes a "Show OS version" step that prints:
Linux:
=== System Information ===
uname -a # Kernel and architecture
=== Architecture ===
uname -m # x86_64, aarch64, etc.
arch # Architecture type
=== CPU Info ===
lscpu # Detailed CPU information
macOS:
=== macOS Version ===
sw_vers # macOS version and build
=== Architecture ===
uname -m # x86_64 or arm64
arch # i386 or arm64
=== CPU Info ===
sysctl machdep.cpu.brand_string # CPU model
Windows:
=== Windows Version ===
systeminfo # OS name and version
ver # Windows version
=== Architecture ===
PROCESSOR_ARCHITECTURE # AMD64, x86, ARM64
| Platform | Runner Label | Architecture | OS Version | Strategy |
|---|---|---|---|---|
| Linux AMD64 | ubuntu-latest | x86_64 | Ubuntu 22.04+ | Auto-update |
| Linux ARM64 | ubuntu-24.04-arm | aarch64 | Ubuntu 24.04 | Free (Public Preview) |
| macOS Intel | macos-15-intel | x86_64 | macOS 15 Sequoia | Pinned |
| macOS Apple Silicon | macos-15 | arm64 | macOS 15 Sequoia | Pinned |
| Windows | windows-latest | x86_64 | Windows Server 2022+ | Auto-update |
| FreeBSD | ubuntu-latest (VM) | x86_64 | FreeBSD 15.0 in VM | VM-based |
We use a hybrid approach to balance stability and maintenance:
Auto-update runners (-latest):
ubuntu-latest - Very stable, rarely breaks, auto-updates to newest Ubuntu LTSwindows-latest - Backward compatible, auto-updates to newest Windows ServerPinned runners (specific versions):
ubuntu-24.04-arm - Free for public repos (Public Preview, may have queue delays)macos-15-intel - Last Intel macOS runner (EOL August 2027)macos-15 - Pin for control over macOS upgradesWhy this approach?
If you experience long waits for ARM64 jobs:
The ubuntu-24.04-arm runner is free for public repositories but is in Public Preview. GitHub warns: "you may experience longer queue times during peak usage hours".
To reduce wait times we should upgrade to Team/Enterprise plan - then we could use ubuntu-24.04-arm64 for faster, paid runners
| Date | Event | Action Required |
|---|---|---|
| August 2027 | macOS Intel runners removed | Must drop Intel macOS testing or use self-hosted |
| TBD | ARM64 runners leave Public Preview | May see improved queue times |
Note: macos-15-intel is the last Intel-based macOS runner from GitHub Actions. After August 2027, only Apple Silicon runners will be available.
The Windows workflow uses:
msys2/setup-msys2@v2 actionilammy/msvc-dev-cmd@v1 for environment setup
MSYS2_PATH_TYPE: inherit to inherit Windows PATHAR=lib.exe, NM=dumpbin.exe, RANLIB=:make (standard in MSYS2)autoconfThis script mirrors the logic from gen_travis.py but generates GitHub Actions workflows instead of .travis.yml. The test matrices are designed to provide equivalent coverage to the Travis CI configuration.
To regenerate all workflows after modifying gen_gh_actions.py:
./scripts/gen_gh_actions.py linux > .github/workflows/linux-ci.yml
./scripts/gen_gh_actions.py macos > .github/workflows/macos-ci.yml
./scripts/gen_gh_actions.py windows > .github/workflows/windows-ci.yml
Note: The generated files should not be edited by hand. All changes should be made to gen_gh_actions.py and then regenerated.