Skip to content

Commit 855bdf5

Browse files
committed
chore: added pages-deploy.yml for workflow
1 parent dc754e7 commit 855bdf5

File tree

1 file changed

+77
-0
lines changed

1 file changed

+77
-0
lines changed

.github/workflows/pages-deploy.yml

Lines changed: 77 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,77 @@
1+
name: "Build and Deploy"
2+
on:
3+
push:
4+
branches:
5+
- main
6+
- master
7+
paths-ignore:
8+
- .gitignore
9+
- README.md
10+
- LICENSE
11+
12+
# Allows you to run this workflow manually from the Actions tab
13+
workflow_dispatch:
14+
15+
permissions:
16+
contents: read
17+
pages: write
18+
id-token: write
19+
20+
# Allow one concurrent deployment
21+
concurrency:
22+
group: "pages"
23+
cancel-in-progress: true
24+
25+
jobs:
26+
build:
27+
runs-on: ubuntu-latest
28+
29+
steps:
30+
- name: Checkout
31+
uses: actions/checkout@v4
32+
with:
33+
fetch-depth: 0
34+
35+
- name: Setup Pages
36+
id: pages
37+
uses: actions/configure-pages@v4
38+
39+
- name: Setup Ruby
40+
uses: ruby/setup-ruby@v1
41+
with:
42+
ruby-version: 3.3
43+
bundler-cache: true
44+
45+
- name: Setup Node
46+
uses: actions/setup-node@v4
47+
with:
48+
node-version: latest
49+
50+
- name: Install Bundler Dependencies
51+
run: bundle install
52+
53+
- name: Build Assets
54+
run: npm install && npm run build
55+
56+
- name: Build site
57+
run: bundle exec jekyll build -d _site
58+
env:
59+
JEKYLL_ENV: "production"
60+
61+
- name: Upload site artifact
62+
uses: actions/upload-pages-artifact@v3
63+
with:
64+
path: _site
65+
66+
deploy:
67+
environment:
68+
name: github-pages
69+
runs-on: ubuntu-latest
70+
needs: build
71+
steps:
72+
- name: Deploy to GitHub Pages
73+
id: deployment
74+
uses: actions/deploy-pages@v4
75+
76+
- name: Output Deployment URL
77+
run: echo "Your site is live at ${{ steps.deployment.outputs.page_url }}"

0 commit comments

Comments
 (0)