Skip to content

ci(*): move to GitHub Actions #1

ci(*): move to GitHub Actions

ci(*): move to GitHub Actions #1

Workflow file for this run

on:
push:
branches: ['master']
env:
NODE_VERSION: '18.x'
jobs:
linux:
runs-on: ubuntu-latest
steps:
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: ${{ env.NODE_VERSION }}
- name: Install dependencies
run: npm ci
# Run tests with
# - Run in band because appears to run more smoothly (avoids memory issues when running in parallel?)
# - Fifteen (!) minute test timeout
# - Force exit to prevent hanging
- name: Run tests
run: npx jest --coverage --runInBand --testTimeout=900000 --forceExit
release:
runs-on: ubuntu-latest
needs: linux
steps:
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: ${{ env.NODE_VERSION }}
- name: Release package
run: |
set -e
npm ci
mkdir -p docs
npx semantic-release
env:
GIT_AUTHOR_NAME: Stencila CI Bot
GIT_AUTHOR_EMAIL: [email protected]
GIT_COMMITTER_NAME: Stencila CI Bot
GIT_COMMITTER_EMAIL: [email protected]
GITHUB_TOKEN: $(GITHUB_TOKEN)
NPM_TOKEN: $(NPM_TOKEN)