From a12fb6276852f2f074199430a9e09db23bcd58e9 Mon Sep 17 00:00:00 2001 From: Danny Guo Date: Sun, 1 Dec 2019 15:13:45 -0500 Subject: [PATCH] Switch to GitHub Actions for CI --- .github/workflows/ci.yml | 31 +++++++++++++++++++++++++++++++ .travis.yml | 5 ----- README.md | 3 ++- 3 files changed, 33 insertions(+), 6 deletions(-) create mode 100644 .github/workflows/ci.yml delete mode 100644 .travis.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..15a9eee --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,31 @@ +name: CI + +on: [push, pull_request] + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v1 + - name: Read .nvmrc + id: nvm + run: echo "##[set-output name=node_version;]$(cat .nvmrc)" + - uses: actions/setup-node@v1 + with: + node-version: "${{ steps.nvm.outputs.node_version }}" + - name: Get the Yarn cache + id: yarn-cache + run: echo "::set-output name=dir::$(yarn cache dir)" + - uses: actions/cache@v1 + with: + path: ${{ steps.yarn-cache.outputs.dir }} + key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} + restore-keys: | + ${{ runner.os }}-yarn- + - name: Install packages + run: yarn install --frozen-lockfile + - name: Check formatting + run: yarn run format:check + - name: Lint the code + run: yarn run lint diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 6c96303..0000000 --- a/.travis.yml +++ /dev/null @@ -1,5 +0,0 @@ -language: node_js - -script: - - yarn run format:check - - yarn run lint diff --git a/README.md b/README.md index 79bea38..89e7949 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,7 @@ # Make a README -[![Build Status](https://travis-ci.org/dguo/make-a-readme.svg?branch=master)](https://travis-ci.org/dguo/make-a-readme) [![Netlify Status](https://api.netlify.com/api/v1/badges/68992d1c-36d4-4a84-b177-00c1f64fbcb4/deploy-status)](https://app.netlify.com/sites/make-a-readme/deploys) +[![Netlify Status](https://api.netlify.com/api/v1/badges/68992d1c-36d4-4a84-b177-00c1f64fbcb4/deploy-status)](https://app.netlify.com/sites/make-a-readme/deploys) +[![CI status](https://github.com/dguo/make-a-readme/workflows/CI/badge.svg)](https://github.com/dguo/make-a-readme/actions?query=branch%3Amaster) [Make a README](https://makeareadme.com) explains what a README is, what the benefits are, and what makes for a good README. It also provides an editable