Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
72 changes: 72 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
name: CI

on:
push:
branches:
- master
pull_request:
branches:
- master

jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
node-version:
- 10.x
- 12.x
- 14.x
- 15.x
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- run: npm ci
- run: npm run build
- run: npm run bundlesize
- name: Save build
if: matrix.node-version == '14.x'
uses: actions/upload-artifact@v2
with:
name: build
path: |
.
!node_modules
retention-days: 1

gh-pages:
needs: test
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/master'
steps:
- uses: actions/download-artifact@v2
with:
name: build
- run: rm .gitignore
- uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: .

npm:
needs: test
runs-on: ubuntu-latest
steps:
- uses: actions/download-artifact@v2
with:
name: build
- uses: actions/setup-node@v1
with:
node-version: 14.x
- uses: rlespinasse/github-slug-action@v3.x
- name: Append commit hash to package version
run: 'sed -i -E "s/(\"version\": *\"[^\"]+)/\1-${GITHUB_SHA_SHORT}/" package.json'
- name: Disable pre- and post-publish actions
run: 'sed -i -E "s/\"((pre|post)publish)/\"ignore:\1/" package.json'
- uses: RubenVerborgh/npm-publish@fix/unpublished-version
with:
token: ${{ secrets.NPM_TOKEN }}
tag: ${{ env.GITHUB_REF_SLUG }}
40 changes: 0 additions & 40 deletions .travis.yml

This file was deleted.

19 changes: 0 additions & 19 deletions travis/bumpversion.js

This file was deleted.