build: support packaged CLI on Node 22.12 (#1116)

This commit is contained in:
Michał Pierzchała
2026-07-06 07:59:37 +02:00
committed by GitHub
parent 83d54614d8
commit 915f5ba374
2 changed files with 33 additions and 1 deletions
+32
View File
@@ -108,6 +108,38 @@ jobs:
# (no deps needed) so the job stays fast and does not require a pnpm install.
run: node --experimental-strip-types scripts/layering/check.ts
packaged-cli-node-22-12:
name: Packaged CLI Node 22.12
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- name: Checkout
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- name: Setup build toolchain
uses: ./.github/actions/setup-node-pnpm
- name: Build and pack CLI
run: |
pnpm build
mkdir -p .tmp/node-compat
npm pack --ignore-scripts --pack-destination .tmp/node-compat
- name: Setup Node.js 22.12
uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
with:
node-version: "22.12"
- name: Install and run global CLI on Node.js 22.12
run: |
set -euo pipefail
prefix="$RUNNER_TEMP/agent-device-node-22-12"
tarball="$(find "$GITHUB_WORKSPACE/.tmp/node-compat" -name 'agent-device-*.tgz' -print -quit)"
test -n "$tarball"
npm install --global --prefix "$prefix" --ignore-scripts "$tarball"
"$prefix/bin/agent-device" --version
"$prefix/bin/agent-device" help
fallow:
name: Fallow Code Quality
runs-on: ubuntu-latest
+1 -1
View File
@@ -64,7 +64,7 @@
}
},
"engines": {
"node": ">=22.19"
"node": ">=22.12"
},
"bin": {
"agent-device": "bin/agent-device.mjs"