Skip to content

Commit

Permalink
Merge pull request #1434 from nextstrain/ci/travis-to-gh
Browse files Browse the repository at this point in the history
Replace TravisCI with GitHub Actions
  • Loading branch information
victorlin authored Nov 19, 2021
2 parents e7b3190 + 6426897 commit d8b3d2a
Show file tree
Hide file tree
Showing 4 changed files with 45 additions and 34 deletions.
53 changes: 43 additions & 10 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,31 @@ on:
push:
branches:
- master
- release
pull_request:
name: ci
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
node: [12, 14, 16]
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node }}
- run: node --version
- run: npm ci
- run: npm run build
unit-test:
runs-on: ubuntu-latest
strategy:
matrix:
node: [10]
node: [12, 14, 16]
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
- uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node }}
- run: node --version
Expand All @@ -22,10 +36,10 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
node: [10]
node: [12, 14, 16]
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
- uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node }}
- run: npm ci
Expand All @@ -35,20 +49,39 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
node: [10]
node: [12, 14, 16]
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
- uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node }}
- run: npm install
- run: npm ci
- run: npm run lint
bundlesize:
runs-on: ubuntu-latest
strategy:
matrix:
node: [12, 14, 16]
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
- uses: actions/setup-node@v2
with:
node-version: 10
- run: npm install
node-version: ${{ matrix.node }}
- run: npm ci
- run: npx bundlesize
publish:
if: ${{ github.ref == 'refs/heads/release' }}
needs: [build, unit-test, smoke-test, lint]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: 14
registry-url: https://registry.npmjs.org/
- run: node --version
- run: npm ci
- run: npm run rebuild-docker-image
- run: npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
21 changes: 0 additions & 21 deletions .travis.yml

This file was deleted.

2 changes: 1 addition & 1 deletion DEV_DOCS.md
Original file line number Diff line number Diff line change
Expand Up @@ -165,4 +165,4 @@ If a translation of a particular string is not yet available, then auspice will

## Releases & versioning

New versions are released via the `./releaseNewVersion.sh` script from an up-to-date `master` branch. It will prompt you for the version number increase, push changes to the `release` branch and, as long as Travis-CI is successful then a new version will be automatically published to [npm](https://www.npmjs.com/package/auspice).
New versions are released via the `./releaseNewVersion.sh` script from an up-to-date `master` branch. It will prompt you for the version number increase, push changes to the `release` branch and, as long as the GitHub workflow is successful then a new version will be automatically published to [npm](https://www.npmjs.com/package/auspice).
3 changes: 1 addition & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
[![Build Status](https://travis-ci.com/nextstrain/auspice.svg?branch=master)](https://travis-ci.com/nextstrain/auspice)
[![GitHub CI Status](https://travis-ci.com/nextstrain/auspice.svg?branch=master)](https://github.com/nextstrain/auspice/actions?query=workflow%3Aci)
[![Build Status](https://github.com/nextstrain/auspice/actions/workflows/ci.yaml/badge.svg?branch=master)](https://github.com/nextstrain/auspice/actions/workflows/ci.yaml?query=branch:master)
[![NPM version](https://img.shields.io/npm/v/auspice.svg?style=flat)](https://www.npmjs.com/package/auspice)
[![License: AGPL v3](https://img.shields.io/badge/License-AGPL%20v3-blue.svg)](https://www.gnu.org/licenses/agpl-3.0)

Expand Down

0 comments on commit d8b3d2a

Please sign in to comment.