From 2b4eb36c70ef624cfced43b41639aa0b1bc33a48 Mon Sep 17 00:00:00 2001 From: Matthew Russell Date: Sun, 15 May 2022 07:59:02 -0700 Subject: [PATCH] Convert from travis to github actions --- .github/workflows/ci.yml | 53 ++++++++++++++++++++++++++++++++++++++++ .travis.yml | 15 ------------ 2 files changed, 53 insertions(+), 15 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..4bf1a81 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,53 @@ +name: CI + +on: + push: + branches: [main] + pull_request: + branches: [main] + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v2 + + - name: Set up PureScript toolchain + uses: purescript-contrib/setup-purescript@main + with: + purescript: "0.14.0" + + - name: Cache PureScript dependencies + uses: actions/cache@v2 + with: + key: ${{ runner.os }}-spago-${{ hashFiles('**/*.dhall') }} + path: | + .spago + output + + - name: Set up Node toolchain + uses: actions/setup-node@v2 + with: + node-version: "14.x" + + - name: Cache NPM dependencies + uses: actions/cache@v2 + env: + cache-name: cache-node-modules + with: + path: ~/.npm + key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package.json') }} + restore-keys: | + ${{ runner.os }}-build-${{ env.cache-name }}- + ${{ runner.os }}-build- + ${{ runner.os }}- + + - name: Install NPM dependencies + run: npm install + + - name: Install spago deps + run: npm run deps + + - name: Build the project + run: npm run build diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index bd93c8a..0000000 --- a/.travis.yml +++ /dev/null @@ -1,15 +0,0 @@ -dist: trusty -sudo: required -language: node_js -node_js: - - node - - "lts/*" - -cache: npm - -install: - - npm ci - - npx bower install - -script: - - npx pulp build