From 4c6aeb9bb2c73de1caf7d64746afe006b3a91759 Mon Sep 17 00:00:00 2001 From: Peter Steinberger Date: Tue, 26 May 2026 13:41:34 +0100 Subject: [PATCH] ci: use local node toolcache setup --- .github/actions/setup-node-env/action.yml | 11 ++++++---- .../actions/setup-pnpm-store-cache/action.yml | 2 +- .github/workflows/ci.yml | 20 +++++++++++-------- 3 files changed, 20 insertions(+), 13 deletions(-) diff --git a/.github/actions/setup-node-env/action.yml b/.github/actions/setup-node-env/action.yml index 14bcb9affa4..571df654286 100644 --- a/.github/actions/setup-node-env/action.yml +++ b/.github/actions/setup-node-env/action.yml @@ -36,10 +36,13 @@ runs: fi - name: Setup Node.js - uses: actions/setup-node@v6 - with: - node-version: ${{ inputs.node-version }} - check-latest: false + shell: bash + env: + REQUESTED_NODE_VERSION: ${{ inputs.node-version }} + run: | + set -euo pipefail + source "$GITHUB_ACTION_PATH/../setup-pnpm-store-cache/ensure-node.sh" + openclaw_ensure_node "$REQUESTED_NODE_VERSION" - name: Setup pnpm uses: ./.github/actions/setup-pnpm-store-cache diff --git a/.github/actions/setup-pnpm-store-cache/action.yml b/.github/actions/setup-pnpm-store-cache/action.yml index 40c8a921210..7f98d327393 100644 --- a/.github/actions/setup-pnpm-store-cache/action.yml +++ b/.github/actions/setup-pnpm-store-cache/action.yml @@ -14,7 +14,7 @@ inputs: required: false default: "" use-actions-cache: - description: Whether pnpm/action-setup should cache the pnpm store. + description: Whether actions/cache should cache the pnpm store. required: false default: "true" outputs: diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index cfb07cd3a9f..fe783579028 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -387,10 +387,12 @@ jobs: pre-commit run --config "${PRE_COMMIT_CONFIG_PATH:-.pre-commit-config.yaml}" zizmor --files "${workflow_files[@]}" - name: Setup Node.js - uses: actions/setup-node@v6 - with: - node-version: "24.x" - check-latest: false + env: + REQUESTED_NODE_VERSION: "24.x" + run: | + set -euo pipefail + source .github/actions/setup-pnpm-store-cache/ensure-node.sh + openclaw_ensure_node "$REQUESTED_NODE_VERSION" - name: Audit production dependencies run: node scripts/pre-commit/pnpm-audit-prod.mjs --audit-level=high @@ -1504,10 +1506,12 @@ jobs: } - name: Setup Node.js - uses: actions/setup-node@v6 - with: - node-version: 24.x - check-latest: false + env: + REQUESTED_NODE_VERSION: "24.x" + run: | + set -euo pipefail + source .github/actions/setup-pnpm-store-cache/ensure-node.sh + openclaw_ensure_node "$REQUESTED_NODE_VERSION" - name: Setup pnpm uses: ./.github/actions/setup-pnpm-store-cache