Skip to content

Commit 81061a8

Browse files
committed
updated docs yml
1 parent 7921bd1 commit 81061a8

File tree

1 file changed

+48
-34
lines changed

1 file changed

+48
-34
lines changed

.github/workflows/docs.yml

Lines changed: 48 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,53 @@
11
name: Deploy GitHub Pages
22

33
on:
4-
push:
5-
branches:
6-
- master
7-
paths:
8-
- 'docs/**'
9-
- '.github/workflows/docs.yml'
4+
push:
5+
branches: [main, master]
6+
paths: ['docs/**']
7+
workflow_dispatch:
8+
9+
permissions:
10+
contents: read
11+
pages: write
12+
id-token: write
13+
14+
concurrency:
15+
group: 'pages'
16+
cancel-in-progress: false
1017

1118
jobs:
12-
build-and-deploy:
13-
runs-on: ubuntu-latest
14-
steps:
15-
- name: Checkout
16-
uses: actions/checkout@v3
17-
18-
- name: Setup Ruby
19-
uses: ruby/setup-ruby@v1
20-
with:
21-
ruby-version: '3.0'
22-
bundler-cache: true
23-
24-
- name: Install Jekyll
25-
run: |
26-
gem install jekyll bundler
27-
bundle install
28-
29-
- name: Build Jekyll site
30-
run: |
31-
cd docs
32-
bundle exec jekyll build
33-
34-
- name: Deploy
35-
uses: JamesIves/github-pages-deploy-action@v4
36-
with:
37-
folder: docs/_site
38-
branch: gh-pages
39-
clean: true
19+
deploy:
20+
environment:
21+
name: github-pages
22+
url: ${{ steps.deployment.outputs.page_url }}
23+
runs-on: ubuntu-latest
24+
steps:
25+
- name: Checkout
26+
uses: actions/checkout@v4
27+
28+
- name: Setup Ruby
29+
uses: ruby/setup-ruby@v1
30+
with:
31+
ruby-version: '3.2'
32+
33+
- name: Install dependencies
34+
run: |
35+
cd docs
36+
bundle install
37+
38+
- name: Build site
39+
run: |
40+
cd docs
41+
bundle exec jekyll build
42+
43+
- name: Setup Pages
44+
uses: actions/configure-pages@v4
45+
46+
- name: Upload artifact
47+
uses: actions/upload-pages-artifact@v3
48+
with:
49+
path: 'docs/_site'
50+
51+
- name: Deploy to GitHub Pages
52+
id: deployment
53+
uses: actions/deploy-pages@v4

0 commit comments

Comments
 (0)