Skip to content

Instantly share code, notes, and snippets.

@byteshiva
Forked from hardfire/eleventy_build.yml
Created April 12, 2021 15:39
Show Gist options
  • Save byteshiva/fca338404a97407a5b2f5dfef85cf601 to your computer and use it in GitHub Desktop.
Save byteshiva/fca338404a97407a5b2f5dfef85cf601 to your computer and use it in GitHub Desktop.
Use this action to build an eleventy site and push to gh-pages
name: Eleventy Build
on: [push]
jobs:
build_deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- name: Build using node.ks
uses: actions/setup-node@v1
with:
node-version: '12.x'
- run: npm install
- run: npm run build --if-present
- name: Deploy
uses: peaceiris/actions-gh-pages@v1.1.0
env:
PUBLISH_DIR: _site
PUBLISH_BRANCH: gh-pages
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment