Skip to content

add workflow

add workflow #1

Workflow file for this run

name: On code change
on: [push, pull_request]
jobs:
build:
name: Build module
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- uses: actions/setup-node@v1
with:
node-version: '10.x'
- name: Install & build with yarn
run: |
yarn install
yarn build
test:
name: Run integration tests
runs-on: ubuntu-latest
needs: build
steps:
- uses: actions/checkout@master
- uses: actions/setup-node@v1
with:
node-version: '10.x'
- name: test with yarn
run: |
yarn test
publish:
name: Publish to npm
runs-on: ubuntu-latest
needs: test
steps:
- uses: actions/checkout@master
- uses: actions/setup-node@v1
with:
node-version: '10.x'
- name: Publish to npm
run: |
echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}" > ~/.npmrc
yarn publish --access public