From 6c2206de536f21e451165b1b8971475ebd5fe103 Mon Sep 17 00:00:00 2001 From: Vincent Weevers Date: Sat, 15 May 2021 10:26:06 +0200 Subject: [PATCH] Move to GitHub Actions --- .github/dependabot.yml | 11 +++++++++++ .github/workflows/release.yml | 18 ++++++++++++++++++ .github/workflows/test.yml | 28 ++++++++++++++++++++++++++++ .npmrc | 1 + .travis.yml | 8 -------- README.md | 6 +++--- 6 files changed, 61 insertions(+), 11 deletions(-) create mode 100644 .github/dependabot.yml create mode 100644 .github/workflows/release.yml create mode 100644 .github/workflows/test.yml create mode 100644 .npmrc delete mode 100644 .travis.yml diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 0000000..171d635 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,11 @@ +version: 2 +updates: + # Disabled until we migrate to remark 13 + # - package-ecosystem: npm + # directory: / + # schedule: + # interval: monthly + - package-ecosystem: github-actions + directory: / + schedule: + interval: monthly diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..fb8bf60 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,18 @@ +name: Release +on: + push: + tags: ['*'] +permissions: + contents: write +jobs: + release: + name: Release + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v2 + - name: Create GitHub release + uses: docker://antonyurchenko/git-release:latest + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + ALLOW_TAG_PREFIX: true diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml new file mode 100644 index 0000000..31d9f3c --- /dev/null +++ b/.github/workflows/test.yml @@ -0,0 +1,28 @@ +name: Test +on: [push, pull_request] +permissions: + contents: read +jobs: + test: + strategy: + matrix: + os: [ubuntu-latest, macos-latest, windows-latest] + node: [10, 12, 14, 16] + runs-on: ${{ matrix.os }} + name: ${{ matrix.os }} / Node ${{ matrix.node }} + steps: + - name: Checkout + uses: actions/checkout@v2 + - name: Cache dependents + uses: actions/cache@v2 + with: + path: dependents + key: ${{ runner.os }}-${{ matrix.node }}-${{ hashFiles('test/dependents.js') }} + - name: Use node ${{ matrix.node }} + uses: actions/setup-node@v2 + with: + node-version: ${{ matrix.node }} + - name: Install + run: npm install + - name: Test + run: npm test diff --git a/.npmrc b/.npmrc new file mode 100644 index 0000000..9cf9495 --- /dev/null +++ b/.npmrc @@ -0,0 +1 @@ +package-lock=false \ No newline at end of file diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index beb53e0..0000000 --- a/.travis.yml +++ /dev/null @@ -1,8 +0,0 @@ -language: node_js -node_js: - - 10 - - 12 - - 14 -cache: - directories: - - dependents diff --git a/README.md b/README.md index 1a429cb..0b20f0a 100644 --- a/README.md +++ b/README.md @@ -5,9 +5,9 @@ [![npm status](http://img.shields.io/npm/v/hallmark.svg)](https://www.npmjs.org/package/hallmark) [![node](https://img.shields.io/node/v/hallmark.svg)](https://www.npmjs.org/package/hallmark) -[![Travis build status](https://img.shields.io/travis/vweevers/hallmark.svg?label=travis)](http://travis-ci.org/vweevers/hallmark) -[![JavaScript Style Guide](https://img.shields.io/badge/code_style-standard-brightgreen.svg)](https://standardjs.com) -[![Markdown Style Guide](https://img.shields.io/badge/md_style-hallmark-brightgreen.svg)](https://www.npmjs.org/package/hallmark) +[![Test](https://img.shields.io/github/workflow/status/vweevers/hallmark/Test?label=test)](https://github.com/vweevers/hallmark/actions/workflows/test.yml) +[![JavaScript Style Guide](https://img.shields.io/badge/standard-informational?logo=javascript&logoColor=fff)](https://standardjs.com) +[![Markdown Style Guide](https://img.shields.io/badge/hallmark-informational?logo=markdown)](https://github.com/vweevers/hallmark) ## Table of Contents