ci: run make test on every PR and push to main
Add .github/workflows/ci.yml (Nim + gcc → make test). Keep selfhost-loop as an optional/weekly job. Document CI layout; reformat hir_lower for fmt-check.
This commit is contained in:
@@ -0,0 +1,52 @@
|
||||
# Default PR / main CI: full `make test` (not selfhost fixed-point — see selfhost-loop.yml).
|
||||
name: ci
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
push:
|
||||
branches: [main]
|
||||
workflow_dispatch:
|
||||
|
||||
concurrency:
|
||||
group: ci-${{ github.workflow }}-${{ github.ref }}
|
||||
cancel-in-progress: true
|
||||
|
||||
jobs:
|
||||
test:
|
||||
name: make test
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 90
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Install Nim
|
||||
uses: jiro4989/setup-nim-action@v2
|
||||
with:
|
||||
nim-version: "2.0.x"
|
||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Install build deps
|
||||
run: |
|
||||
sudo apt-get update
|
||||
sudo apt-get install -y --no-install-recommends \
|
||||
gcc make binutils libssl-dev python3
|
||||
|
||||
- name: Bootstrap + full test suite
|
||||
env:
|
||||
# Ensure registry / selfhost smokes see a clean env
|
||||
BUX_NO_LINE: ""
|
||||
run: |
|
||||
unset BUX_DEBUG_FILE || true
|
||||
unset BUX_SELFHOST_FIXED_POINT || true
|
||||
make test
|
||||
|
||||
- name: Upload selfhost artifacts on failure
|
||||
if: failure()
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: ci-failure-logs
|
||||
path: |
|
||||
build/selfhost/build/main.c
|
||||
_test_tmp_pkg/**
|
||||
if-no-files-found: ignore
|
||||
@@ -1,13 +1,13 @@
|
||||
# Optional / not on every PR: bootstrap selfhost determinism (make selfhost-loop).
|
||||
# Triggers: manual, weekly, or push to main that touches compiler/stdlib/loop.
|
||||
# Fixed-point buxc2→buxc3 is opt-in via BUX_SELFHOST_FIXED_POINT=1 (experimental).
|
||||
# Default PR CI is .github/workflows/ci.yml (`make test`).
|
||||
# Fixed-point gen2 vs gen3: BUX_SELFHOST_FIXED_POINT=1 (workflow_dispatch input).
|
||||
name: selfhost-loop
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
fixed_point:
|
||||
description: "Also run experimental buxc2→buxc3 fixed-point"
|
||||
description: "Also run fixed-point buxc2→buxc3→buxc4 (gen2 vs gen3)"
|
||||
type: boolean
|
||||
default: false
|
||||
schedule:
|
||||
|
||||
Reference in New Issue
Block a user