Skip to content

Instantly share code, notes, and snippets.

@elzup
Created October 9, 2019 02:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save elzup/989d262faa254ccce18caa3333fa2d7e to your computer and use it in GitHub Desktop.
Save elzup/989d262faa254ccce18caa3333fa2d7e to your computer and use it in GitHub Desktop.
GithubActions gh-pages deploy
name: GitHub Pages
on:
push:
branches:
- master
jobs:
build-deploy:
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@master
- name: setup node
uses: actions/setup-node@v1
with:
node-version: '10.16'
- name: Build and Deploy
uses: JamesIves/github-pages-deploy-action@master
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
BASE_BRANCH: master # The branch the action should deploy from.
BRANCH: gh-pages # The branch the action should deploy to.
FOLDER: build # The folder the action should deploy.
BUILD_SCRIPT: yarn install && yarn build && touch ./build/.nojekyll
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment