Skip to content

Update node.js.yml #467

Update node.js.yml

Update node.js.yml #467

Workflow file for this run

# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs
name: Run Build and Unit Tests
on:
push:
branches: ["development"]
pull_request:
branches: ["development"]
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [20.x]
steps:
- uses: actions/checkout@v3
- name: Build Using Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: "npm"
- run: npm ci
- run: npm run build
test:
- runs-on: ubuntu-latest

Check failure on line 28 in .github/workflows/node.js.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/node.js.yml

Invalid workflow file

You have an error in your yaml syntax on line 28
strategy:
matrix:
node-version: [20.x]
- needs: build
- steps:
- uses: actions/setup-node@v3
- run: npm test
archive:
- runs-on: ubuntu-latest
- needs: test
- strategy:
matrix:
node-version: [20.x]
- steps:
- name: Archive production artifacts
uses: actions/upload-artifact@v3
with:
name: nib-static-site
path: |
public/neurodiversity-main/
create-release:
- runs-on: ubuntu-latest
- name: Create Release
- steps:
id: create_release
uses: ncipollo/release-action@v1
with:
tag: "nightly-tag-${{ steps.date.outputs.date }}"
artifacts: "release.zip"
prerelease: true