Update _config.yml #190
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 and Deploy" | |
on: | |
push: | |
branches: | |
- main | |
- master | |
paths-ignore: | |
- .gitignore | |
- README.md | |
- LICENSE | |
# Allows you to run this workflow manually from the Actions tab | |
workflow_dispatch: | |
permissions: | |
contents: read | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
submodules: true | |
# If using the 'assets' git submodule from Chirpy Starter, uncomment above | |
# (See: https://github.com/cotes2020/chirpy-starter/tree/main/assets) | |
- name: Setup Ruby | |
uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: 3.2 | |
bundler-cache: true | |
- name: Install Jekyll dependencies | |
run: gem install bundler && bundle install | |
- name: Build Jekyll site | |
run: bundle exec jekyll build | |
deploy: | |
environment: | |
name: cloudflare-pages | |
url: ${{ steps.deployment.outputs.page_url }} | |
runs-on: ubuntu-latest | |
needs: build | |
steps: | |
- name: Deploy to Cloudflare Pages | |
uses: cloudflare/[email protected] | |
with: | |
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }} | |
script: "wrangler publish" |