Skip to content

Commit

Permalink
ci: fix setup-node for npm publish
Browse files Browse the repository at this point in the history
  • Loading branch information
jlopezcur committed Dec 2, 2024
1 parent 3bd1aee commit e59bb08
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
3 changes: 0 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,5 @@ jobs:
git config --global user.name 'Devo GitHub Action'
git config --global user.email '[email protected]'
- name: Build
run: npm run build

- name: Publish ${{ github.event.inputs.version }}${{ github.event.inputs.dry == 'true' && ' (--dry-run)' || '' }}
run: npm run release:ci -- ${{ github.event.inputs.version != 'auto' && github.event.inputs.version || '' }}${{ github.event.inputs.dry == 'true' && ' --dry-run' || '' }}
9 changes: 9 additions & 0 deletions .github/workflows/setup-node/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ runs:
uses: actions/setup-node@v4
with:
node-version: 22
cache: npm
registry-url: https://registry.npmjs.org/

- name: Cache dependencies ⚡
id: cache_dependencies
Expand All @@ -15,6 +17,13 @@ runs:
path: node_modules
key: node-modules-${{ hashFiles('package-lock.json') }}

- name: Cache dist ⚡
id: cache_dist
uses: actions/cache@v4
with:
path: '**/dist'
key: dist-${{ github.sha }}

- name: Install dependencies 🔧
shell: bash
if: steps.cache_dependencies.outputs.cache-hit != 'true'
Expand Down

0 comments on commit e59bb08

Please sign in to comment.