Switched to GitHub Actions for lint testing

no issue
This commit is contained in:
Daniel Lockyer 2020-01-29 16:46:11 +00:00
parent a7fde48d1d
commit ef551768bb
2 changed files with 18 additions and 7 deletions

17
.github/workflows/lint.yml vendored Normal file
View File

@ -0,0 +1,17 @@
name: Lint Check
on:
pull_request:
push:
branches:
- master
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: '10'
- run: yarn install
- run: yarn lint

View File

@ -13,19 +13,13 @@ env:
matrix: matrix:
- DB=sqlite3 NODE_ENV=testing - DB=sqlite3 NODE_ENV=testing
- DB=mysql NODE_ENV=testing-mysql - DB=mysql NODE_ENV=testing-mysql
matrix:
include:
- node_js: '10'
env: TEST_SUITE=lint
install: install:
- yarn - yarn
before_script: before_script:
- if [ $DB == "mysql" ]; then mysql -e 'create database ghost_testing'; fi - if [ $DB == "mysql" ]; then mysql -e 'create database ghost_testing'; fi
- if [ "$DB" == "sqlite3" ]; then yarn add --force sqlite3; fi - if [ "$DB" == "sqlite3" ]; then yarn add --force sqlite3; fi
script: | script: |
if [ "$TEST_SUITE" == "lint" ]; then if [[ "$TRAVIS_PULL_REQUEST_BRANCH" =~ ^renovate || "$TRAVIS_EVENT_TYPE" == "cron" ]]; then
yarn lint
elif [[ "$TRAVIS_PULL_REQUEST_BRANCH" =~ ^renovate || "$TRAVIS_EVENT_TYPE" == "cron" ]]; then
yarn ci:regression yarn ci:regression
else else
yarn ci yarn ci