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-
61# Sample workflow for building and deploying a Jekyll site to GitHub Pages
72name : Deploy Jekyll site to Pages
83
@@ -33,20 +28,41 @@ jobs:
3328 steps :
3429 - name : Checkout
3530 uses : actions/checkout@v4
36- - name : Setup Ruby
37- uses : ruby/setup-ruby@8575951200e472d5f2d95c625da0c7bec8217c42 # v1.161.0
38- with :
39- ruby-version : ' 3.2.2' # Not needed with a .ruby-version file
40- bundler-cache : true # runs 'bundle install' and caches installed gems automatically
41- cache-version : 0 # Increment this number if you need to re-download cached gems
31+
32+ # Replace ruby/setup-ruby with manual Ruby installation steps
33+ - name : Install dependencies
34+ run : |
35+ sudo apt-get update
36+ sudo apt-get install -y build-essential libssl-dev zlib1g-dev libreadline-dev
37+
38+ - name : Clone ruby-build
39+ run : |
40+ git clone https://github.com/rbenv/ruby-build.git
41+ sudo PREFIX=/usr/local ./ruby-build/install.sh
42+
43+ - name : Install Ruby
44+ run : |
45+ ruby-build 3.2.2 /opt/hostedtoolcache/Ruby/3.2.2/x64
46+
47+ - name : Mark Ruby Installation as Complete
48+ run : |
49+ touch /opt/hostedtoolcache/Ruby/3.2.2/x64.complete
50+
51+ - name : Update PATH
52+ run : |
53+ echo "/opt/hostedtoolcache/Ruby/3.2.2/x64/bin" >> $GITHUB_PATH
54+
55+ # Continue with the rest of the workflow
4256 - name : Setup Pages
4357 id : pages
4458 uses : actions/configure-pages@v5
59+
4560 - name : Build with Jekyll
4661 # Outputs to the './_site' directory by default
4762 run : bundle exec jekyll build --baseurl "${{ steps.pages.outputs.base_path }}"
4863 env :
4964 JEKYLL_ENV : production
65+
5066 - name : Upload artifact
5167 # Automatically uploads an artifact from the './_site' directory by default
5268 uses : actions/upload-pages-artifact@v3
6177 steps :
6278 - name : Deploy to GitHub Pages
6379 id : deployment
64- uses : actions/deploy-pages@v4
80+ uses : actions/deploy-pages@v4
0 commit comments