优化工作流

home
PJ568 1 year ago
parent 993e07d323
commit a3d137a52f

@ -7,7 +7,7 @@ on:
- '!gh-pages' - '!gh-pages'
jobs: jobs:
build: deploy:
runs-on: ubuntu-latest runs-on: ubuntu-latest
permissions: permissions:
contents: write # To push a branch contents: write # To push a branch
@ -19,13 +19,19 @@ jobs:
ref: home ref: home
submodules: recursive submodules: recursive
- name: 获取发行版 - name: Get Release
uses: robinraju/release-downloader@v1.9
with:
repository: "PJ-568/568_Calc"
latest: true
fileName: "Web.zip"
- name: Release
run: | run: |
mkdir ./Web mkdir ./Web
/usr/bin/wget https://gitee.com/PJ-568/568_Calc/releases/download/v0.0.0.3/Web.zip -O ./Web.zip unzip -o $GITHUB_WORKSPACE/Web.zip -d ./Web
unzip -o ./Web.zip -d ./Web
ls ./Web ls ./Web
rm ./Web.zip rm $GITHUB_WORKSPACE/Web.zip
- name: Generate the sitemap - name: Generate the sitemap
id: sitemap id: sitemap
@ -39,8 +45,8 @@ jobs:
echo "url-count = ${{ steps.sitemap.outputs.url-count }}" echo "url-count = ${{ steps.sitemap.outputs.url-count }}"
echo "excluded-count = ${{ steps.sitemap.outputs.excluded-count }}" echo "excluded-count = ${{ steps.sitemap.outputs.excluded-count }}"
# Deploy - name: Deploy
- uses: JamesIves/github-pages-deploy-action@v4 uses: JamesIves/github-pages-deploy-action@v4
with: with:
branch: gh-pages # The branch the action should deploy to. branch: gh-pages # The branch the action should deploy to.
folder: . # The folder the action should deploy. folder: . # The folder the action should deploy.

Loading…
Cancel
Save