Fix broken Nightly Workflow (#1076) #2763
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node | |
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions | |
name: Node.js CI | |
on: | |
workflow_dispatch: null | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
permissions: | |
issues: read | |
pull-requests: read | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
include: | |
- node-version: 16.x | |
targets: node16 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Use Node.js ${{ matrix.node-version }} | |
uses: actions/setup-node@v3 | |
with: | |
node-version: ${{ matrix.node-version }} | |
- run: npm ci | |
- run: npm run build -w packages/notification | |
- run: npm test && npx codecov | |
- run: npm pack | |
- run: npm install -g ./hyperjumptech-monika-*.tgz | |
- run: npm run prod_test | |
- run: npm run pkg -- -t ${{ matrix.targets }}-linux-x64 | |
name: Pack the binary using vercel/pkg | |
- run: ./dist/monika -v | |
name: Test if printing the version is not error | |
build-on-node-js-18: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Use Node.js 18.x | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 18.x | |
- run: npm ci | |
- run: npm run build -w packages/notification | |
- run: NODE_OPTIONS='--no-experimental-fetch' npm test && npx codecov | |
- run: npm pack | |
- run: npm install -g ./hyperjumptech-monika-*.tgz | |
- run: npm run prod_test | |
- run: | | |
echo "No node18 target supported yet, using node16..." | |
npm run pkg -- -t node16-linux-x64 | |
name: Pack the binary using vercel/pkg | |
- run: ./dist/monika -v | |
name: Test if printing the version is not error |