Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 37 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,43 @@ jobs:
exit 1
fi

lint:
name: Lint & Format
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- name: Checkout
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2

- name: Setup toolchain
uses: ./.github/actions/setup-node-pnpm

- name: Run oxlint
run: pnpm lint

- name: Check formatting
run: pnpm format:check

layering-guard:
name: Layering Guard (warn-only)
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- name: Checkout
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2

- name: Warn on commands/ imports below the CLI surface layer
run: |
# daemon/ and platforms/ should not depend on the CLI commands layer.
# Warn-only until the shared contracts move out of src/commands/;
# flip to a hard failure once existing imports are migrated.
matches=$(rg -n "from '.*commands/" src/daemon src/platforms --glob '!**/__tests__/**' --glob '!*.test.ts' || true)
if [ -n "$matches" ]; then
echo "$matches"
count=$(printf '%s\n' "$matches" | wc -l)
echo "::warning title=Layering drift::$count import(s) of src/commands/* from src/daemon or src/platforms. New code should depend on shared contracts instead."
fi

fallow:
name: Fallow Code Quality
runs-on: ubuntu-latest
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@
"perf:android": "node --experimental-strip-types scripts/perf/run.ts --platform android",
"lint": "oxlint . --deny-warnings",
"format": "oxfmt --write src test skills package.json tsconfig.json tsconfig.lib.json rslib.config.ts vitest.config.ts .github/actions/setup-node-pnpm/action.yml .oxlintrc.json .oxfmtrc.json '!test/skillgym/.skillgym-results/**'",
"format:check": "oxfmt --check src test skills package.json tsconfig.json tsconfig.lib.json rslib.config.ts vitest.config.ts .github/actions/setup-node-pnpm/action.yml .oxlintrc.json .oxfmtrc.json '!test/skillgym/.skillgym-results/**'",
"fallow": "fallow --summary",
"fallow:baseline": "(fallow dead-code --save-baseline fallow-baselines/dead-code.json --summary || true) && (fallow health --save-baseline fallow-baselines/health.json --summary || true)",
"check:fallow": "fallow audit",
Expand Down
Loading