-
Notifications
You must be signed in to change notification settings - Fork 0
48 lines (38 loc) · 1.08 KB
/
build-website.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
name: Build and publish
on:
workflow_dispatch:
push:
branches: [ main ]
# Make sure jobs cannot overlap (e.g. one from push and one from schedule).
concurrency:
group: published-ci
cancel-in-progress: true
jobs:
build:
name: Build and deploy to the gh-pages branch
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
ref: 'main'
# Configure the build environment.
- name: Install Ruby 3.1
uses: ruby/setup-ruby@v1
with:
ruby-version: '3.1'
# Runs 'bundle install' and caches installed gems automatically
bundler-cache: true
# Build the website.
- name: Build the static website
run: bundle exec jekyll build
# Publish the build results
- name: Deploy to the gh-pages branch 🚀
uses: JamesIves/github-pages-deploy-action@v4
with:
branch: gh-pages
folder: _site
# Configure the commit author.
git-config-name: 'ci-deploy'
git-config-email: '<>'
# Remove outdated files from the target directory.
clean: true