2019-09-15 01:22:02 +02:00
|
|
|
name: Build and deploy website
|
2020-03-19 23:54:58 +01:00
|
|
|
|
2019-09-15 01:22:02 +02:00
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- master
|
2020-03-19 23:54:58 +01:00
|
|
|
|
2019-09-15 01:22:02 +02:00
|
|
|
jobs:
|
2020-03-19 23:54:58 +01:00
|
|
|
build-deploy:
|
2019-09-15 01:22:02 +02:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- name: Checkout repository
|
2020-03-19 23:54:58 +01:00
|
|
|
uses: actions/checkout@v2
|
2019-09-15 01:22:02 +02:00
|
|
|
|
|
|
|
- name: Install Node v12
|
|
|
|
uses: actions/setup-node@v1
|
|
|
|
with:
|
|
|
|
node-version: 12
|
|
|
|
|
|
|
|
- name: Build website
|
|
|
|
run: |
|
|
|
|
npm install
|
|
|
|
npm run build
|
|
|
|
|
2020-03-19 23:54:58 +01:00
|
|
|
- name: Add .nojekyll
|
2019-09-15 01:33:38 +02:00
|
|
|
run: touch ./public/.nojekyll
|
|
|
|
|
2019-09-15 01:22:02 +02:00
|
|
|
- name: Deploy website
|
2020-03-19 23:54:58 +01:00
|
|
|
uses: peaceiris/actions-gh-pages@v3
|
|
|
|
with:
|
|
|
|
deploy_key: ${{ secrets.ACTIONS_DEPLOY_KEY }}
|
|
|
|
publish_branch: gh-pages
|
|
|
|
publish_dir: ./public
|
|
|
|
user_name: 'github-actions[bot]'
|
|
|
|
user_email: 'github-actions[bot]@users.noreply.github.com'
|
|
|
|
commit_message: ${{ github.event.head_commit.message }}
|