diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f31e27d..95f7d42 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -86,10 +86,14 @@ jobs: with: node-version: "lts/*" - - name: login to verdaccio + - name: login to 'verdaccio' run: npx npm-cli-login -u test -p 1234 -e test@domain.test -r http://localhost:4873 - - name: publish to verdaccio + - name: version for 'verdaccio' + run: | + npm version patch --commit-hooks false --git-tag-version false + + - name: publish to 'verdaccio' run: | npm publish --registry http://localhost:4873 @@ -114,6 +118,10 @@ jobs: fail-fast: false steps: + - uses: actions/checkout@v4 + # with: + # submodules: "recursive" + - uses: actions/download-artifact@v4 with: name: artifact @@ -122,6 +130,26 @@ jobs: with: node-version: "lts/*" + - uses: pnpm/action-setup@v2 + name: Install pnpm + with: + version: 8 + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + - uses: actions/cache@v3 + name: Setup pnpm cache + if: ${{ inputs.cache }} + with: + path: | + ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + - name: Install Dependencies + run: pnpm add @actions/core -D + - name: config for test run: | mkdir ../temp diff --git a/scripts/getversion.mjs b/scripts/getversion.mjs index efc782d..8816fb0 100644 --- a/scripts/getversion.mjs +++ b/scripts/getversion.mjs @@ -1,5 +1,6 @@ import { readFileSync } from "node:fs"; -import * as core from "@actions/core"; +import { exportVariable } from "@actions/core"; const { version } = JSON.parse(readFileSync("package.json")); console.info(version); -core.exportVariable("version", version); +// process.stdout.write(`::set-env name=version::${version}`); +exportVariable("version", version);