Skip to content

workflow artifacts test #21

workflow artifacts test

workflow artifacts test #21

Workflow file for this run

# This workflow will run tests using node and then publish a package to GitHub Packages when a release is created
# For more information see: https://docs.github.com/en/actions/publishing-packages/publishing-nodejs-packages
name: Node.js Package
on:
push:
branches:
- '**'
release:
types: [created]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v3
with:
node-version: 20
- name: Build frontend
run: |
cd client
npm run build
- name: Build backend
run: |
cd server
npm ci
- uses: actions/upload-artifact@v4
with:
name: frontend-artifact
path: client/dist
publish-npm:
# if: github.event_name == 'release'
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v3
with:
node-version: 20
registry-url: https://registry.npmjs.org/
- name: Download frontend artifact
uses: actions/download-artifact@v4
with:
name: frontend-artifact
path: server/src/public
- run: |
cd server

Check failure on line 50 in .github/workflows/npm-publish.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/npm-publish.yml

Invalid workflow file

You have an error in your yaml syntax on line 50
npm ci
- run: npm version --no-git-tag-version ${{ github.ref_name }}
# - run: npm publish --allow-same-version
env:
NODE_AUTH_TOKEN: ${{secrets.npm_token}}