Skip to content

Commit

Permalink
Configure GitHub Actions CI
Browse files Browse the repository at this point in the history
  • Loading branch information
meganindya committed Jan 8, 2021
1 parent 20a9689 commit b83e620
Showing 1 changed file with 60 additions and 0 deletions.
60 changes: 60 additions & 0 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
---
#######################
#######################
## CI GitHub Actions ##
#######################
#######################
name: Continuous Integration

#
# Documentation:
# https://help.github.com/en/articles/workflow-syntax-for-github-actions
#

#############################
# Start the job on all push #
#############################
on:
push:
branches: [develop, main]
pull_request:
branches: [develop, main]

###############
# Set the Job #
###############
jobs:
build:
# Name the Job
name: Continuous Integration
# Set the agent to run on
runs-on: ubuntu-latest

strategy:
matrix:
node-version: [12.x, 14.x]

##################
# Load all steps #
##################
steps:
##########################
# Checkout the code base #
##########################
- uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}

###################
# Run npm scripts #
###################

- run: npm ci
# - run: npm run build --if-present
- run: npm test --if-present
env:
DEFAULT_BRANCH: develop

0 comments on commit b83e620

Please sign in to comment.