40 lines
1.0 KiB
YAML
40 lines
1.0 KiB
YAML
# 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: publish
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
publication:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
|
|
- uses: actions/setup-node@v1
|
|
with:
|
|
node-version: 18
|
|
registry-url: https://registry.npmjs.org/
|
|
|
|
- name: install
|
|
run: npm ci
|
|
|
|
- name: build
|
|
run: npm run build
|
|
|
|
- name: browser tests
|
|
run: npm run test:browser-headless
|
|
|
|
- name: node tests and coverage
|
|
run: npm run coverage
|
|
|
|
- name: send report to coveralls.io
|
|
uses: coverallsapp/github-action@master
|
|
with:
|
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
- name: publish to NPM
|
|
run: npm publish
|
|
env:
|
|
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} |