-
Notifications
You must be signed in to change notification settings - Fork 0
55 lines (48 loc) · 1.47 KB
/
publish.yaml
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
49
50
51
52
53
54
55
name: publish
on: [push, workflow_dispatch]
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Git checkout
uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "21.6.1"
- run: npm install
- run: npm run format
- name: Commit changes
uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: Apply formatting changes
branch: ${{ github.head_ref }}
- name: Retrieve theme
run: git submodule update --init --recursive
- name: Setup hugo
uses: peaceiris/actions-hugo@v2
with:
hugo-version: "0.122.0"
extended: true
- name: Build
run: hugo --minify
- name: Add README
run: |
echo "This site is generated from github.com/bpcreech/blog" > ./public/README
- name: Grab latest asteroids build
uses: robinraju/[email protected]
with:
out-file-path: ./public/asteroids
repository: bpcreech/typescript-asteroids
latest: true
extract: true
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
with:
personal_token: ${{ secrets.TOKEN }}
external_repository: bpcreech/bpcreech.github.io
publish_dir: ./public
# keep_files: true
user_name: bpcreech
user_email: [email protected]
publish_branch: main
cname: bpcreech.com