Skip to content
This repository has been archived by the owner on Apr 6, 2023. It is now read-only.

Commit

Permalink
ci: Setup CI workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
diego3g committed Feb 25, 2020
1 parent af1a82d commit 9a6bd17
Show file tree
Hide file tree
Showing 4 changed files with 44 additions and 25 deletions.
3 changes: 1 addition & 2 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@ module.exports = {
jsx: true,
tsx: true,
},
sourceType: 'module',
project: resolve(__dirname, 'tsconfig.json'),
sourceType: 'module'
},
parser: '@typescript-eslint/parser',
plugins: [
Expand Down
41 changes: 41 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: ci

on:
pull_request:

jobs:
build:
runs-on: ubuntu-latest

env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

steps:
- name: Checkout repository
uses: actions/checkout@v2
with:
fetch-depth: 0

- name: Set up Node
uses: actions/setup-node@v1
with:
node-version: 12

- name: Install dependencies
run: yarn

- name: Check tests
run: yarn test --coverage

- name: Check linting
run: yarn lint

- name: Check commit message
uses: wagoid/commitlint-github-action@v1

- name: Coveralls
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.GITHUB_TOKEN }}


22 changes: 0 additions & 22 deletions .github/workflows/test.yml

This file was deleted.

3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@
"prebuild": "lerna exec --parallel -- rimraf dist typings",
"build": "lerna exec --parallel -- rollup -c ../../rollup.config.js",
"test": "jest",
"coveralls": "jest && cat ./__tests__/coverage/lcov.info | coveralls"
"lint": "eslint packages --ext ts,tsx",
"coveralls": "cat ./coverage/lcov.info | coveralls"
},
"devDependencies": {
"@babel/core": "^7.4.3",
Expand Down

0 comments on commit 9a6bd17

Please sign in to comment.