Repository navigation
Validate notarized CLI artifacts after transport #422
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| pull_request: | |
| branches: | |
| - main | |
| - alpha | |
| - beta | |
| push: | |
| branches-ignore: | |
| - main | |
| - alpha | |
| - beta | |
| jobs: | |
| ahtraces-component: | |
| if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.fork == false | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v7 | |
| - name: Read pinned ahtraces revision | |
| id: ahtraces-ref | |
| shell: bash | |
| run: | | |
| set -euo pipefail | |
| revision=$(tr -d '[:space:]' < .github/ahtraces-ref) | |
| if ! [[ "$revision" =~ ^[0-9a-f]{40}$ ]]; then | |
| echo "::error::.github/ahtraces-ref must contain one full commit SHA" | |
| exit 1 | |
| fi | |
| echo "sha=$revision" >> "$GITHUB_OUTPUT" | |
| - name: Checkout pinned ahtraces component | |
| uses: actions/checkout@v7 | |
| with: | |
| repository: autohandai/ahtraces | |
| ref: ${{ steps.ahtraces-ref.outputs.sha }} | |
| path: ahtraces-component | |
| token: ${{ secrets.AHTRACES_REPO_TOKEN }} | |
| persist-credentials: false | |
| - uses: actions/setup-node@v7 | |
| with: | |
| node-version: 24 | |
| package-manager-cache: false | |
| - uses: oven-sh/setup-bun@v2 | |
| with: | |
| bun-version-file: package.json | |
| - name: Install ahtraces dependencies | |
| working-directory: ahtraces-component | |
| run: bun install --frozen-lockfile | |
| - name: Prove independently built component | |
| working-directory: ahtraces-component | |
| run: bun run proof | |
| - name: Compile and smoke test component | |
| working-directory: ahtraces-component | |
| env: | |
| BUILD_GIT_COMMIT: ${{ steps.ahtraces-ref.outputs.sha }} | |
| run: | | |
| bun run compile:linux-x64 | |
| ./binaries/ahtraces-linux-x64 --version | |
| ./binaries/ahtraces-linux-x64 --help > /dev/null | |
| test: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| shard: [1, 2, 3] | |
| steps: | |
| - uses: actions/checkout@v7 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v7 | |
| with: | |
| node-version: 24 | |
| package-manager-cache: false | |
| - name: Setup Bun | |
| uses: oven-sh/setup-bun@v2 | |
| with: | |
| bun-version-file: package.json | |
| - name: Install build tools (Ubuntu) | |
| if: runner.os == 'Linux' | |
| run: sudo apt-get update && sudo apt-get install -y build-essential python3 make g++ | |
| - name: Install dependencies | |
| run: bun install --frozen-lockfile | |
| - name: Type check | |
| run: bun run typecheck | |
| - name: Run tests | |
| run: bun run test:ci -- --shard=${{ matrix.shard }}/3 | |
| tuistory: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| shard: [1, 2, 3, 4] | |
| steps: | |
| - uses: actions/checkout@v7 | |
| with: | |
| # The built terminal tests assert the CLI renders the latest stable | |
| # release tag, which they find with `git tag --merged HEAD`. | |
| fetch-depth: 0 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v7 | |
| with: | |
| node-version: 24 | |
| package-manager-cache: false | |
| - name: Setup Bun | |
| uses: oven-sh/setup-bun@v2 | |
| with: | |
| bun-version-file: package.json | |
| - name: Install build tools (Ubuntu) | |
| run: sudo apt-get update && sudo apt-get install -y build-essential python3 make g++ | |
| - name: Install dependencies | |
| run: bun install --frozen-lockfile | |
| - name: Build CLI for terminal tests | |
| run: bun run build | |
| - name: Run built terminal tests | |
| run: bun run test:tuistory -- --shard=${{ matrix.shard }}/4 | |
| build-test: | |
| # These jobs build independently, so report platform failures alongside the suites. | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| matrix: | |
| os: [macos-26, ubuntu-latest, windows-latest] | |
| steps: | |
| - uses: actions/checkout@v7 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v7 | |
| with: | |
| node-version: 24 | |
| package-manager-cache: false | |
| - name: Setup Bun | |
| uses: oven-sh/setup-bun@v2 | |
| with: | |
| bun-version-file: package.json | |
| - name: Install build tools (Ubuntu) | |
| if: runner.os == 'Linux' | |
| run: sudo apt-get update && sudo apt-get install -y build-essential python3 make g++ | |
| - name: Install dependencies | |
| run: bun install --frozen-lockfile | |
| - name: Test Windows installer architecture detection | |
| if: runner.os == 'Windows' | |
| shell: pwsh | |
| run: bun run test -- tests/windowsInstaller.spec.ts | |
| - name: Build | |
| run: bun run build | |
| - name: Test compilation | |
| env: | |
| AUTOHAND_BUILD_GIT_COMMIT: ${{ github.sha }} | |
| run: | | |
| mkdir -p binaries | |
| # See release.yml's Compile binary step: node-llama-cpp's dynamic | |
| # platform-binary resolution can't be statically bundled. | |
| bun build ./src/index.ts --compile --external node-llama-cpp '--env=AUTOHAND_BUILD_*' --outfile ./binaries/autohand-test | |
| - name: Verify fresh alpha installation | |
| if: runner.os != 'Windows' | |
| shell: bash | |
| timeout-minutes: 5 | |
| env: | |
| AUTOHAND_SKIP_COMPUTER_CONTROL_INSTALL: '1' | |
| run: sh src/testing/scenarios/fresh-alpha-install.sh ./binaries/autohand-test ci-alpha-smoke | |
| - name: Verify Git Bash shell execution | |
| if: runner.os == 'Windows' | |
| shell: bash | |
| timeout-minutes: 10 | |
| run: | | |
| cygpath --version | |
| bun run test:ci tests/windowsShell.integration.test.ts tests/ui/ink/TeamPanel.test.tsx | |
| - name: Verify binary (Unix) | |
| if: runner.os != 'Windows' | |
| run: | | |
| chmod +x ./binaries/autohand-test | |
| ./binaries/autohand-test --help | |
| - name: Smoke test Windows binary | |
| if: runner.os == 'Windows' | |
| shell: pwsh | |
| timeout-minutes: 1 | |
| run: | | |
| $binary = (Resolve-Path "./binaries/autohand-test.exe").Path | |
| & $binary --version | |
| if ($LASTEXITCODE -ne 0) { | |
| throw "Windows --version smoke test failed with exit code $LASTEXITCODE" | |
| } | |
| & $binary --help | Out-Null | |
| if ($LASTEXITCODE -ne 0) { | |
| throw "Windows --help smoke test failed with exit code $LASTEXITCODE" | |
| } | |
| windows-tuistory: | |
| runs-on: windows-latest | |
| timeout-minutes: 15 | |
| steps: | |
| - uses: actions/checkout@v7 | |
| with: | |
| fetch-depth: 0 | |
| - uses: actions/setup-node@v7 | |
| with: | |
| node-version: 24 | |
| package-manager-cache: false | |
| - uses: oven-sh/setup-bun@v2 | |
| with: | |
| bun-version-file: package.json | |
| - name: Install dependencies | |
| run: bun install --frozen-lockfile | |
| - name: Build CLI for terminal tests | |
| run: bun run build | |
| - name: Verify native team recovery from Git Bash | |
| shell: bash | |
| run: bun run test:tuistory tests/tuistory/team-activity.tuistory.test.ts |