From d7020e7a53550af9f80313c684812151476ddad4 Mon Sep 17 00:00:00 2001 From: Amin Yahyaabadi Date: Sat, 26 Oct 2024 02:57:23 -0700 Subject: [PATCH] ci: download pack after checkout + enable node 10 --- .github/workflows/CI.yml | 12 ++++++------ script/smoke-test.bash | 6 +++--- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index 9a164506..7923ec5e 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -239,14 +239,9 @@ jobs: - macos-14 - macos-13 node-version: - # - 10 + - 10 - 22 steps: - - name: Download Pack - uses: actions/download-artifact@v4 - with: - name: pack - - name: Install Node uses: actions/setup-node@v4 with: @@ -276,5 +271,10 @@ jobs: - uses: actions/checkout@v4 + - name: Download Pack + uses: actions/download-artifact@v4 + with: + name: pack + - name: Smoke Test run: bash ./script/smoke-test.bash diff --git a/script/smoke-test.bash b/script/smoke-test.bash index 9610ea37..c0e560a4 100755 --- a/script/smoke-test.bash +++ b/script/smoke-test.bash @@ -6,7 +6,7 @@ echo "Pack zeromq.js if needed" version=$(node -e 'console.log(require("./package.json").version)') pack_name="zeromq-${version}.tgz" echo "${pack_name}" -test -f "${pack_name}" || ls -R +test -f "${pack_name}" || npm pack init_smoke_test() { local pm=$1 @@ -15,8 +15,8 @@ init_smoke_test() { rm -rf "./smoke-test-${pm}" mkdir "./smoke-test-${pm}" cd "./smoke-test-${pm}" - npm init -q --init-module "smoke-test-${pm}" -y - npm pkg set dependencies.zeromq="file:../${pack_name}" || (jq '.dependencies.zeromq = "file:../${pack_name}"' package.json >temp.json && mv temp.json package.json) + npm init -y + npm pkg set dependencies.zeromq="file:../${pack_name}" || jq '.dependencies.zeromq = "file:../${pack_name}"' package.json >temp.json && mv temp.json package.json } package_managers=(npm pnpm yarn)