CI workflow (Acode-Foundation/Acode)
The CI workflow from Acode-Foundation/Acode, explained and optimized by Latchkey.
CI health: B - good
Point runs-on at Latchkey and get run de-duplication, SHA-pinned actions, self-healing for flaky steps, and up to 58% lower cost, applied automatically.
What it does
This is the CI workflow from the Acode-Foundation/Acode repository, a real project running GitHub Actions. It is shown here with attribution under its MIT license.
Below, Latchkey shows a faster, safer version produced by its optimization engine.
The workflow
name: CI
on:
push:
pull_request:
jobs:
spell-check:
timeout-minutes: 5
name: Check spelling
runs-on: ubuntu-latest
steps:
- name: Checkout Actions Repository
uses: actions/checkout@v7
- name: Check spelling
uses: crate-ci/typos@master
with:
config: ./_typos.toml
quality:
timeout-minutes: 5
name: Linting and formatting
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v7
- name: Setup Biome
uses: biomejs/setup-biome@v2
- name: Run Biome
run: biome ci .
translation-check:
name: Translation Check (On PR Only)
timeout-minutes: 5
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: read
if: github.event_name == 'pull_request'
steps:
- name: Checkout Repository
uses: actions/checkout@v7
- name: Use Node.js
uses: actions/setup-node@v6
with:
cache: npm
cache-dependency-path: '**/package-lock.json'
- name: Detect Changed Files
uses: dorny/paths-filter@v4
id: file-changes
with:
list-files: shell
filters: |
translation:
- 'src/lang/*.json'
token: ${{ secrets.GITHUB_TOKEN }}
- name: Translation Files Check (if changed)
if: steps.file-changes.outputs.translation == 'true'
run: |
npm ci --no-audit --no-fund
npm run lang checkThe same workflow, on Latchkey
Removes redundant runs and caps runaway jobs. Added and changed lines are highlighted.
name: CI on: push: pull_request: concurrency: group: ${{ github.workflow }}-${{ github.ref }} cancel-in-progress: true jobs: spell-check: timeout-minutes: 5 name: Check spelling runs-on: latchkey-small steps: - name: Checkout Actions Repository uses: actions/checkout@v7 - name: Check spelling uses: crate-ci/typos@master with: config: ./_typos.toml quality: timeout-minutes: 5 name: Linting and formatting runs-on: latchkey-small steps: - name: Checkout repository uses: actions/checkout@v7 - name: Setup Biome uses: biomejs/setup-biome@v2 - name: Run Biome run: biome ci . translation-check: name: Translation Check (On PR Only) timeout-minutes: 5 runs-on: latchkey-small permissions: contents: read pull-requests: read if: github.event_name == 'pull_request' steps: - name: Checkout Repository uses: actions/checkout@v7 - name: Use Node.js uses: actions/setup-node@v6 with: cache: npm cache-dependency-path: '**/package-lock.json' - name: Detect Changed Files uses: dorny/paths-filter@v4 id: file-changes with: list-files: shell filters: | translation: - 'src/lang/*.json' token: ${{ secrets.GITHUB_TOKEN }} - name: Translation Files Check (if changed) if: steps.file-changes.outputs.translation == 'true' run: | npm ci --no-audit --no-fund npm run lang check
What changed
- Run on Latchkey managed runners with one line (
runs-on), which apply the fixes below automatically and self-heal transient failures. This example useslatchkey-small; pick the runner size that fits the job. - Cancel superseded runs when a branch or PR gets a newer push.
3 third-party actions are referenced by a movable tag. Pin them to the commit SHA (Latchkey resolves and applies this automatically) so a repointed tag cannot change what runs.
What Latchkey heals here
This workflow has steps that commonly fail on transient issues (network, registries, flaky browsers). On Latchkey managed runners they are detected, retried, and self-healed instead of failing your build:
- Dependency installs
This workflow runs 3 jobs per trigger. On Latchkey the same minutes cost up to 58% less than GitHub-hosted, with zero queue time.