Skip to content

Add @types/amqplib to prod dependencies. #273

Add @types/amqplib to prod dependencies.

Add @types/amqplib to prod dependencies. #273

Workflow file for this run

#
# Run tests and publish to NPM when merged to master branch
#
name: CI
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
tests:
name: Build and run unit tests
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [16.x, 18.x, 20.x]
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 i
- run: npm run lint
- run: npm test
publish:
name: Publish to NPM registry
runs-on: ubuntu-latest
if: github.event_name == 'push' && github.ref == 'refs/heads/master'
needs: [tests]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 20.x
registry-url: https://registry.npmjs.org
- run: npm publish --access public
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}