更新下载链接

This commit is contained in:
jimmy committed 2025-01-05 21:16:45 +08:00
1 parent 353d716902
commit c266e86a12
1 file changed
+6 -15
+6 -15
View File
@@ -14,27 +14,18 @@ jobs:
with:
submodules: true
- name: Checkout destination
uses: actions/checkout@v3
if: github.ref == 'refs/heads/main'
with:
ref: gh-pages
path: built-site
- name: Setup Hugo
run: |
curl -L -o /tmp/hugo.tar.gz 'https://github.com/gohugoio/hugo/releases/download/v0.110.0/hugo_extended_0.110.0_linux-amd64.tar.gz'
curl -L -o /tmp/hugo.tar.gz 'https://github.com/gohugoio/hugo/releases/download/v0.112.4/hugo_extended_0.110.0_linux-amd64.deb'
tar -C ${RUNNER_TEMP} -zxvf /tmp/hugo.tar.gz hugo
- name: Build
run: ${RUNNER_TEMP}/hugo
- name: Deploy
if: github.ref == 'refs/heads/main'
run: |
cp -R public/* ${GITHUB_WORKSPACE}/built-site/
cd ${GITHUB_WORKSPACE}/built-site
git add .
git config user.name 'dhij'
git config user.email 'davidhwang.ij@gmail.com'
git config --global user.name 'dhij'
git config --global user.email 'davidhwang.ij@gmail.com'
git add -A
git commit -m 'Updated site'
git push
git push https://${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }} main