Skip to content

🔧 chore[workflow]: setup github workflow #14

🔧 chore[workflow]: setup github workflow

🔧 chore[workflow]: setup github workflow #14

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: Node.js CI
on:
push:
branches: ["master", "develop"]
pull_request:
branches: ["master", "develop"]
jobs:
build:
runs-on: self-hosted
strategy:
matrix:
node-version: [22.x]
steps:
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
working-directory: milkyway-bot/report-server
run: |
npm install actions/setup-node@v4
actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- run: npm ci
working-directory: milkyway-bot/report-server
- run: npm run build --if-present
working-directory: milkyway-bot/report-server
- run: npm test
working-directory: milkyway-bot/report-server