Add CI config for GitHub actions
This commit is contained in:
parent
e9d39ae0c9
commit
30825ba0e6
2 changed files with 38 additions and 0 deletions
37
.github/workflows/ci.yml
vendored
Normal file
37
.github/workflows/ci.yml
vendored
Normal file
|
@ -0,0 +1,37 @@
|
|||
name: CI
|
||||
|
||||
on: [push, pull_request]
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
|
||||
- uses: actions/checkout@v1
|
||||
with:
|
||||
submodules: true
|
||||
|
||||
- name: Setup Hugo
|
||||
uses: peaceiris/actions-hugo@v2
|
||||
with:
|
||||
hugo-version: '0.68.3'
|
||||
extended: true
|
||||
|
||||
- name: Setup node
|
||||
uses: actions/setup-node@v1
|
||||
with:
|
||||
node-version: '10.x'
|
||||
|
||||
- uses: actions/cache@v1
|
||||
with:
|
||||
path: $HOME/.npm
|
||||
key: npm-${{ hashFiles('package-lock.json') }}
|
||||
|
||||
- name: Install Dependencies
|
||||
run: npm ci
|
||||
|
||||
- name: Build site
|
||||
run: ./scripts/release.sh
|
||||
|
||||
- name: Run tests
|
||||
run: ./scripts/test.sh
|
|
@ -2,5 +2,6 @@
|
|||
|
||||
[![Circle CI](https://circleci.com/gh/RealOrangeOne/theorangeone.net.svg?style=svg)](https://circleci.com/gh/RealOrangeOne/theorangeone.net)
|
||||
![Deploy](https://github.com/RealOrangeOne/theorangeone.net/workflows/Deploy/badge.svg)
|
||||
![CI](https://github.com/RealOrangeOne/theorangeone.net/workflows/CI/badge.svg)
|
||||
|
||||
https://theorangeone.net
|
||||
|
|
Loading…
Reference in a new issue