Skip to content

Update ci.yml (#160) #254

Update ci.yml (#160)

Update ci.yml (#160) #254

Workflow file for this run

name: CI
on:
pull_request:
push:
branches:
- master
tags:
- 'v*.*.*'
jobs:
ci:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup NodeJS
uses: actions/setup-node@v4
with:
node-version: '16'
registry-url: https://registry.npmjs.org
- name: Installing Dependencies
run: npm i
- name: Lint
run: npm run lint
- name: Build
run: npm run build
- name: Run Tests
run: |
touch .env
echo 'METACALL_AUTH_EMAIL="${{ secrets.METACALL_AUTH_EMAIL }}"' >> .env
echo 'METACALL_AUTH_PASSWORD="${{ secrets.METACALL_AUTH_PASSWORD }}"' >> .env
npm run coverage
- name: Publish
uses: JS-DevTools/npm-publish@v1
if: startsWith(github.ref, 'refs/tags/')
with:
access: 'public'
token: '${{ secrets.NPM_AUTH_TOKEN }}'