Update Events “race-trauma-identity-and-the-arts” #262
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build to GitHub pages | |
on: | |
# schedule: | |
# - cron: '30 01 * 06-07 *' | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
jobs: | |
build: | |
runs-on: ubuntu-22.04 | |
steps: | |
### PREP ### | |
- name: Checkout repo | |
uses: actions/[email protected] | |
with: | |
persist-credentials: false # needed for JamesIves/github-pages-deploy-action | |
### RUBY ### | |
- name: Install Ruby | |
uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: 2.6.3 | |
- name: Cache Ruby gems | |
id: cache-gems | |
uses: actions/cache@v2 | |
with: | |
path: vendor/bundle | |
key: ${{ runner.os }}-gems-1-${{ hashFiles('Gemfile.lock') }} | |
- name: Set deployment flag | |
run: bundle config set --local deployment 'true' | |
- name: Set Ruby gems directory | |
run: bundle config path vendor/bundle | |
- name: Install Ruby gems | |
run: bundle install --jobs 4 --retry 3 | |
#- name: Install node | |
# run: npm install | |
### BUILD ### | |
- name: Build Jekyll | |
run: bundle exec jekyll build | |
### HTMLTEST ### | |
# (This tool makes sure all the links work; may require some tweaking and is optional) | |
# You may find it helpful to create a .htmltest.yml file to set a config. Go wild. | |
- name: Cache htmltest files | |
uses: actions/cache@v2 | |
with: | |
path: tmp/htmltest | |
key: htmltest-1 | |
- name: Test built site with htmltest | |
uses: wjdp/[email protected] | |
continue-on-error: true | |
with: | |
path: _site | |
### DEPLOY ### | |
- name: Publish to GH Pages 🚀 | |
if: ${{ github.event_name == 'push' || github.event_name == 'schedule' && github.ref == 'refs/heads/main' }} | |
uses: JamesIves/[email protected] | |
with: | |
BRANCH: gh-pages # The branch the action should deploy to. | |
FOLDER: _site # The folder the action should deploy. | |
CLEAN: true # Automatically remove deleted files from the deploy branch | |
### SUCCESS ### |