allow workflow to be run from the Actions tab #21
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: Publish to GitHub Pages | |
on: | |
push: | |
branches: [main, master] | |
# Allows you to run this workflow manually from the Actions tab | |
workflow_dispatch: | |
concurrency: | |
group: pages | |
cancel-in-progress: true | |
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages | |
permissions: | |
contents: read | |
pages: write | |
id-token: write | |
jobs: | |
jekyll: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
# Use the GitHub Actions cache to shorten build times and decrease load on servers | |
- uses: actions/cache@v2 | |
with: | |
path: vendor/bundle | |
key: ${{ runner.os }}-gems-${{ hashFiles('Gemfile') }} | |
restore-keys: ${{ runner.os }}-gems- | |
# Standard usage | |
- uses: helaili/jekyll-action@v2 | |
with: | |
pre_build_commands: | | |
sed -i "s/^#baseurl: .*/baseurl: \/${{ github.event.repository.name }}/" _config.yml | |
gem update --system | |
token: ${{ secrets.GITHUB_TOKEN }} |