refactor: removed redundant 'async' #54
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
name: Test & Publish | |
on: [push, pull_request] | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
node-version: [10.x, 12.x] | |
steps: | |
- name: Checkout 🛎️ | |
uses: actions/[email protected] | |
with: | |
persist-credentials: false | |
- name: Setup 🔧 | |
uses: actions/[email protected] | |
with: | |
node-version: ${{ matrix.node-version }} | |
- name: Install ♻ | |
run: npm install | |
- name: Lint 👓 | |
run: npm run lint | |
- name: Test ✅ | |
run: npm run test | |
publish: | |
needs: test | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout 🛎️ | |
uses: actions/[email protected] | |
with: | |
persist-credentials: false | |
- name: Check Version Changes ↗ | |
uses: EndBug/[email protected] | |
id: check | |
- name: Setup 🔧 | |
if: steps.check.outputs.changed == 'true' | |
uses: actions/[email protected] | |
with: | |
node-version: 12 | |
registry-url: https://registry.npmjs.org | |
- name: Install ♻ | |
if: steps.check.outputs.changed == 'true' | |
run: npm install | |
- name: Publish 🚀 | |
if: steps.check.outputs.changed == 'true' | |
run: npm publish | |
env: | |
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} |