Skip to content
Permalink
Browse files
chore: move danger to GH action
also convert dangerfile to typescript
  • Loading branch information
G-Rath committed Oct 27, 2019
1 parent 6de136a commit 24ddc1bc4b6f500268211079b1af74e24e84c5ca
Showing with 478 additions and 75 deletions.
  1. +1 −1 .eslintrc.js
  2. +0 −11 .github/workflows/commitlint.yml
  3. +24 −0 .github/workflows/lint.yml
  4. +1 −2 .github/workflows/nodejs.yml
  5. +0 −7 .travis.yml
  6. +1 −4 dangerfile.js → dangerfile.ts
  7. +1 −0 package.json
  8. +450 −50 yarn.lock
@@ -63,7 +63,7 @@ module.exports = {
globals,
},
{
files: 'src/**/*',
files: ['src/**/*', 'dangerfile.ts'],
parserOptions: {
sourceType: 'module',
},

This file was deleted.

@@ -0,0 +1,24 @@
name: Lint
on: [pull_request]

jobs:
commitlint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: wagoid/commitlint-github-action@v1.2.2
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
danger:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions/setup-node@v1
with:
node-version: 12.x
- name: install
run: yarn
- name: Danger
run: yarn danger ci
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
@@ -50,8 +50,7 @@ jobs:

steps:
- uses: actions/checkout@v1
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
- uses: actions/setup-node@v1
with:
node-version: 12.x
- name: install
@@ -12,13 +12,6 @@ before_script: greenkeeper-lockfile-update
script:
- yarn test --coverage --maxWorkers 2
after_script: greenkeeper-lockfile-upload
jobs:
include:
- stage: danger
node_js: lts/*
os: linux
script:
- npx -p danger@^3 danger ci
cache:
yarn: true
branches:
@@ -1,7 +1,4 @@
'use strict';

// eslint-disable-next-line node/no-missing-require
const { danger, fail } = require('danger');
import { danger } from 'danger';

// Ensure that people include a description on their PRs
if (danger.github.pr.body.length === 0) {
@@ -54,6 +54,7 @@
"@typescript-eslint/parser": "^2.5.0",
"babel-jest": "^24.9.0",
"babel-plugin-replace-ts-export-assignment": "^0.0.2",
"danger": "^9.2.2",
"eslint": "^5.1.0 || ^6.0.0",
"eslint-config-prettier": "^6.5.0",
"eslint-plugin-eslint-plugin": "^2.0.0",

0 comments on commit 24ddc1b

Please sign in to comment.