Skip to content

Commit 0ca3d8e

Browse files
authored
Update main.yml
1 parent 66fb7a8 commit 0ca3d8e

File tree

1 file changed

+23
-10
lines changed

1 file changed

+23
-10
lines changed

.github/workflows/main.yml

Lines changed: 23 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -52,18 +52,31 @@ jobs:
5252
run: |
5353
sudo apt-get update
5454
sudo apt-get install -y imagemagick libheif-dev
55-
find ./content/posts/building-a-workout-page/ -type f \( -name "*.jpg" -o -name "*.png" -o -name "*.jpeg" \) -exec convert {} {}.webp \;
56-
find ./content/posts/building-a-workout-page/ -type f \( -name "*.jpg" -o -name "*.png" -o -name "*.jpeg" \) -exec convert {} {}.avif \;
57-
ls -l ./content/posts/building-a-workout-page/
55+
find ./content/posts/ -type f \( -name "*.jpg" -o -name "*.png" -o -name "*.jpeg" \) -exec convert {} {}.webp \;
56+
find ./content/posts/ -type f \( -name "*.jpg" -o -name "*.png" -o -name "*.jpeg" \) -exec convert {} {}.avif \;
5857
59-
github_pages:
60-
name: Build and Publish Github Pages
61-
uses: ./.github/workflows/gh-pages.yml
62-
secrets:
63-
TOKEN: ${{ secrets.TOKEN }}
64-
needs:
65-
- start
58+
- name: Checkout submodules
59+
run: git submodule update --init --recursive --remote
60+
61+
- name: Setup Hugo
62+
uses: peaceiris/actions-hugo@v3
63+
with:
64+
hugo-version: 'latest'
65+
extended: true
66+
67+
- name: Build
68+
run: |
69+
ls -l ./
70+
hugo --gc --minify --cleanDestinationDir
6671
72+
- name: Push
73+
uses: peaceiris/actions-gh-pages@v4
74+
with:
75+
github_token: ${{ secrets.TOKEN }}
76+
publish_branch: master
77+
force_orphan: true
78+
publish_dir: ./public
79+
cname: liudon.com
6780
ipfs:
6881
name: Build and Publish IPFS
6982
uses: ./.github/workflows/ipfs.yml

0 commit comments

Comments
 (0)