Skip to content

Update deploy.yml

Update deploy.yml #19

Workflow file for this run

name: Deploy Website
on:
push:
branches:
- main
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
with:
submodules: true
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: 3.0
- name: Install Bundler
run: gem install bundler -v 2.4.22 --no-document --user-install
- name: Build and deploy
run: |
# Fetch latest changes from the main branch
git fetch origin main
# Reset the local main branch to match the fetched changes
git reset --hard origin/main
# Run any build commands if necessary
~/.gem/ruby/*/bin/bundle install --path vendor/bundle
~/.gem/ruby/*/bin/bundle exec jekyll build
# npm & Hugo extension :
npm install
npm run build
hugo --minify