fix(ci): aggiunge input npm-version per compatibilità lockfile npm@11
- quality-gates.yml: nuovo input npm-version con step condizionale upgrade - docker-release.yml: idem - examples/documentazione: ci.yml e release.yml passano npm-version: '11' Fixes #2 @25m
This commit is contained in:
@@ -6,6 +6,9 @@ on:
|
|||||||
node-version:
|
node-version:
|
||||||
type: string
|
type: string
|
||||||
default: '22.17'
|
default: '22.17'
|
||||||
|
npm-version:
|
||||||
|
type: string
|
||||||
|
default: ''
|
||||||
runner:
|
runner:
|
||||||
type: string
|
type: string
|
||||||
default: 'catthehacker-latest'
|
default: 'catthehacker-latest'
|
||||||
@@ -22,6 +25,10 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
node-version: ${{ inputs.node-version || '22.17' }}
|
node-version: ${{ inputs.node-version || '22.17' }}
|
||||||
|
|
||||||
|
- name: Upgrade npm
|
||||||
|
if: inputs.npm-version != ''
|
||||||
|
run: npm install -g npm@${{ inputs.npm-version }}
|
||||||
|
|
||||||
- name: Cache npm
|
- name: Cache npm
|
||||||
uses: https://gitea.com/actions/cache@v4
|
uses: https://gitea.com/actions/cache@v4
|
||||||
with:
|
with:
|
||||||
|
|||||||
@@ -6,6 +6,9 @@ on:
|
|||||||
node-version:
|
node-version:
|
||||||
type: string
|
type: string
|
||||||
default: '22.17'
|
default: '22.17'
|
||||||
|
npm-version:
|
||||||
|
type: string
|
||||||
|
default: ''
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
quality-gates:
|
quality-gates:
|
||||||
@@ -19,6 +22,10 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
node-version: ${{ inputs.node-version || '22.17' }}
|
node-version: ${{ inputs.node-version || '22.17' }}
|
||||||
|
|
||||||
|
- name: Upgrade npm
|
||||||
|
if: inputs.npm-version != ''
|
||||||
|
run: npm install -g npm@${{ inputs.npm-version }}
|
||||||
|
|
||||||
- name: Cache npm
|
- name: Cache npm
|
||||||
uses: https://gitea.com/actions/cache@v4
|
uses: https://gitea.com/actions/cache@v4
|
||||||
with:
|
with:
|
||||||
|
|||||||
@@ -22,5 +22,5 @@ jobs:
|
|||||||
quality-gates:
|
quality-gates:
|
||||||
uses: https://gitea.pzetatouch.it/devops/shared-actions/.gitea/workflows/quality-gates.yml@v1
|
uses: https://gitea.pzetatouch.it/devops/shared-actions/.gitea/workflows/quality-gates.yml@v1
|
||||||
secrets: inherit
|
secrets: inherit
|
||||||
# with:
|
with:
|
||||||
# node-version: '22.17' # opzionale, default già impostato
|
npm-version: '11' # lockfile generato con npm@11, runner usa npm@10 di default
|
||||||
|
|||||||
@@ -22,6 +22,7 @@ jobs:
|
|||||||
secrets: inherit
|
secrets: inherit
|
||||||
with:
|
with:
|
||||||
runner: catthehacker-latest # runner con Docker pre-installato
|
runner: catthehacker-latest # runner con Docker pre-installato
|
||||||
|
npm-version: '11' # lockfile generato con npm@11, runner usa npm@10 di default
|
||||||
|
|
||||||
auto-release:
|
auto-release:
|
||||||
needs: [docker-release]
|
needs: [docker-release]
|
||||||
|
|||||||
Reference in New Issue
Block a user