Skip to content

Commit

Permalink
Migrate CI to GitHub Actions
Browse files Browse the repository at this point in the history
  • Loading branch information
danielbayley committed Oct 13, 2020
1 parent fd85c6d commit 45ed168
Show file tree
Hide file tree
Showing 4 changed files with 37 additions and 25 deletions.
35 changes: 35 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: CI
on:
push:
branches: master
pull_request:

jobs:
test:
name: Node v${{ matrix.node-version }} on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
node-version: [ 10.x, 12.x, 13.x, 14.x ]
os: [ ubuntu-latest, macos-latest, windows-latest ]

steps:
- uses: actions/checkout@v2

- uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}

- name: Cache node_modules
uses: actions/cache@v2
with:
path: '**/node_modules'
key: ${{ runner.os }}-node_modules-${{ hashFiles('**/package.json') }}
restore-keys: |
${{ runner.os }}-node_modules-
${{ runner.os }}-
- run: npm install

- run: npm test
5 changes: 0 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
[![badge][ci]][circle]

[_Jest_] + [CoffeeScript]
=========================
Easily write your [_Jest_]s in CoffeeScript.
Expand Down Expand Up @@ -29,9 +27,6 @@ License
[MIT]: LICENSE.md
[Daniel Bayley]: https://github.com/danielbayley

[ci]: https://img.shields.io/circleci/project/danielbayley/jest-preset-coffeescript.svg?style=flat-square
[circle]: https://circleci.com/gh/danielbayley/jest-preset-coffeescript

[_jest_]: https://facebook.github.io/jest
[_transform_]: https://facebook.github.io/jest/docs/en/configuration.html#transform-object-string-string

Expand Down
18 changes: 0 additions & 18 deletions circle.yml

This file was deleted.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -73,15 +73,15 @@
"scripts": {
"prepare": "coffee --compile --bare --transpile *.coffee",
"precommit": "lint-staged",
"prepublishOnly": "CI=true npm test",
"prepublishOnly": "GITHUB_ACTIONS=true npm test",
"prerelease": "git stash --include-untracked",
"release": "npm version --",
"postversion": "git push --follow-tags && npm publish && git stash pop --index",
"pretest": "npm run prepare",
"test": "npm run test.lint && npm run test.jest",
"test.lint": "npm run test.lint.coffee",
"test.lint.coffee": "coffeelint -- *.coffee test/*.*coffee*",
"test.jest": "jest ${CI+--ci --all --no-cache}",
"test.jest": "jest ${GITHUB_ACTIONS+--ci --all --no-cache}",
"clean": "rm -f jest-preset.js* & jest --clearCache --config {}"
}
}

0 comments on commit 45ed168

Please sign in to comment.