Skip to content

Commit

Permalink
ci: migrate to github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
jkusa committed Mar 30, 2021
1 parent 53d0497 commit 6cd2e0b
Show file tree
Hide file tree
Showing 8 changed files with 43,200 additions and 12,080 deletions.
83 changes: 83 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
name: CI

on:
pull_request:
push:
# filtering branches here prevents duplicate builds from pull_request and push
branches:
- main
schedule:
- cron: '0 3 * * 0' # every Sunday at 3am

env:
CI: true

jobs:
tests:
if: "! contains(toJSON(github.event.commits.*.message), '[skip ci]')"
name: Base Tests
timeout-minutes: 5
runs-on: ubuntu-latest
strategy:
matrix:
node:
- '12'
- '14'
steps:
- uses: actions/checkout@v2
- uses: volta-cli/action@v1
with:
node-version: ${{ matrix.node }}

- run: npm ci

- name: Test with ${{ matrix.node }}
run: npm run test:ember

floating-dependencies:
if: "! contains(toJSON(github.event.commits.*.message), '[skip ci]')"
name: Floating Dependencies
timeout-minutes: 5
runs-on: ubuntu-latest
strategy:
matrix:
node:
- '12'
- '14'

steps:
- uses: actions/checkout@v2
- uses: volta-cli/action@v1
with:
node-version: ${{ matrix.node }}

- run: npm install --no-package-lock
- name: Test with Node ${{ matrix.node }}
run: npm run test:ember

try-scenarios:
if: "! contains(toJSON(github.event.commits.*.message), '[skip ci]')"
name: 'Compatibility'
timeout-minutes: 5
runs-on: ubuntu-latest
needs: tests

strategy:
fail-fast: true
matrix:
ember-try-scenario:
- ember-lts-3.16
- ember-lts-3.20
- ember-release
- ember-beta
- ember-canary
- ember-classic
steps:
- uses: actions/checkout@v2
- uses: volta-cli/action@v1
with:
node-version: 12.x
- name: install dependencies
run: npm ci
- name: test
run: node_modules/.bin/ember try:one ${{ matrix.ember-try-scenario }} --skip-cleanup
29 changes: 29 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Lint

on:
pull_request:
push:
# filtering branches here prevents duplicate builds from pull_request and push
branches:
- master

env:
CI: true

jobs:
source:
if: "! contains(toJSON(github.event.commits.*.message), '[skip ci]')"
name: Source
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: volta-cli/action@v1

- run: npm ci

- name: ESLint
run: npm run lint:js

- name: Templates
run: npm run lint:hbs
66 changes: 0 additions & 66 deletions .travis.yml

This file was deleted.

8 changes: 4 additions & 4 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@

- `git clone <repository-url>`
- `cd ember-cli-clipboard`
- `yarn install`
- `npm install`

## Linting

- `yarn lint:hbs`
- `yarn lint:js`
- `yarn lint:js --fix`
- `npm run lint:hbs`
- `npm run lint:js`
- `npm run lint:js --fix`

## Running tests

Expand Down
19 changes: 9 additions & 10 deletions config/ember-try.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,23 +4,22 @@ const getChannelURL = require('ember-source-channel-url');

module.exports = async function () {
return {
useYarn: true,
scenarios: [
{
name: 'ember-lts-3.16',
npm: {
devDependencies: {
'ember-source': '~3.16.0'
}
}
'ember-source': '~3.16.0',
},
},
},
{
name: 'ember-lts-3.20',
npm: {
devDependencies: {
'ember-source': '~3.20.5'
}
}
'ember-source': '~3.20.5',
},
},
},
{
name: 'ember-release',
Expand Down Expand Up @@ -55,9 +54,9 @@ module.exports = async function () {
},
npm: {
devDependencies: {
'@ember/jquery': '^1.1.0'
}
}
'@ember/jquery': '^1.1.0',
},
},
},
{
name: 'ember-classic',
Expand Down
Loading

0 comments on commit 6cd2e0b

Please sign in to comment.