1+ # This workflow uses actions that are not certified by GitHub.
2+ # They are provided by a third-party and are governed by
3+ # separate terms of service, privacy policy, and support
4+ # documentation.
5+
16# Sample workflow for building and deploying a Jekyll site to GitHub Pages
2- name : Deploy Jekyll with GitHub Pages dependencies preinstalled
7+ name : Deploy Jekyll site to Pages
38
49on :
510 # Runs on pushes targeting the default branch
611 push :
7- branches :
8- - main
12+ branches : [$default-branch]
913
1014 # Allows you to run this workflow manually from the Actions tab
1115 workflow_dispatch :
@@ -30,21 +34,24 @@ jobs:
3034 - name : Checkout
3135 uses : actions/checkout@v4
3236 - name : Setup Ruby
33- uses : ruby/setup-ruby@v1
37+ # https://github.com/ruby/setup-ruby/releases/tag/v1.207.0
38+ uses : ruby/setup-ruby@4a9ddd6f338a97768b8006bf671dfbad383215f4
3439 with :
35- ruby-version : ' 3.1'
36- bundler-cache : true
37-
40+ ruby-version : ' 3.1' # Not needed with a .ruby-version file
41+ bundler-cache : true # runs 'bundle install' and caches installed gems automatically
42+ cache-version : 0 # Increment this number if you need to re-download cached gems
3843 - name : Install dependencies
3944 run : bundle install
4045 - name : Setup Pages
46+ id : pages
4147 uses : actions/configure-pages@v5
4248 - name : Build with Jekyll
43- uses : actions/jekyll-build-pages@v1
44- with :
45- source : ./
46- destination : ./_site
49+ # Outputs to the './_site' directory by default
50+ run : bundle exec jekyll build --baseurl "${{ steps.pages.outputs.base_path }}"
51+ env :
52+ JEKYLL_ENV : production
4753 - name : Upload artifact
54+ # Automatically uploads an artifact from the './_site' directory by default
4855 uses : actions/upload-pages-artifact@v3
4956
5057 # Deployment job
5764 steps :
5865 - name : Deploy to GitHub Pages
5966 id : deployment
60- uses : actions/deploy-pages@v4
67+ uses : actions/deploy-pages@v4
0 commit comments