Skip to content

Commit

Permalink
Merge pull request #1448 from GMOD/1328_build_workflow
Browse files Browse the repository at this point in the history
Move building and testing from Travis to GitHub Workflow
  • Loading branch information
rbuels authored Nov 16, 2020
2 parents fc1f0af + 1a280f5 commit 4ff75c2
Show file tree
Hide file tree
Showing 4 changed files with 50 additions and 42 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: Pull Request

on: [pull_request]
on: pull_request

jobs:
lint:
Expand Down
48 changes: 48 additions & 0 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
name: Push

on: push

jobs:
test:
name: Test and typecheck on node 10.x and ubuntu-latest
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Use Node.js 10.x
uses: actions/setup-node@v1
with:
node-version: 10.x
- name: Install deps and build (with cache)
uses: bahmutov/npm-install@v1
- name: Test codebase
run: yarn test-ci
- name: Upload coverage
run: bash <(curl -s https://codecov.io/bash)
- name: Typecheck codebase
run: yarn typecheck

build:
name: Build on node 10.x and ubuntu-latest
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Use Node.js 10.x
uses: actions/setup-node@v1
with:
node-version: 10.x
- name: Install deps and build (with cache)
uses: bahmutov/npm-install@v1
- name: Build codebase
run: yarn build
- name: Test build
run: BUILT_TESTS=1 yarn built-test-ci
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: us-east-1
- name: Copy branch build to S3
run: |
cp products/jbrowse-web/build/test_data/config.json products/jbrowse-web/build/config.json
aws s3 sync --delete products/jbrowse-web/build s3://jbrowse.org/code/jb2/$(echo ${{github.ref}} | cut -d "/" -f3-)
40 changes: 0 additions & 40 deletions .travis.yml

This file was deleted.

2 changes: 1 addition & 1 deletion products/jbrowse-web/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"dir": "src",
"scripts": {
"start": "rescripts --max-http-header-size=100000 start",
"build": "rescripts build",
"build": "cross-env NODE_OPTIONS='--max-old-space-size=7000' rescripts build",
"test": "rescripts test",
"eject": "rescripts eject",
"checktypes": "tsc --noEmit",
Expand Down

0 comments on commit 4ff75c2

Please sign in to comment.