Skip to content

Commit

Permalink
build: 复刻仓库未启用Pages时工作流不应失败
Browse files Browse the repository at this point in the history
  • Loading branch information
XeroAlpha committed Apr 10, 2024
1 parent 064f87e commit 6f81f3f
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ jobs:
yarn build
- name: Deploy to self-hosted site
if: github.repository == 'XeroAlpha/caidlist'
run: |
pushd ${{ github.workspace }}/web/dist
tar -cvzf ${{ github.workspace }}/idlist.tar.gz *
Expand All @@ -67,13 +68,17 @@ jobs:
rm ${{ github.workspace }}/key.txt
- name: Setup GitHub Pages
id: pages_setup
uses: actions/configure-pages@v4
continue-on-error: true

- name: Upload artifact to GitHub pages
if: ${{ steps.pages_setup.outcome == 'success' }}
uses: actions/upload-pages-artifact@v3
with:
path: ${{ github.workspace }}/web/dist

- name: Deploy to GitHub Pages
if: ${{ steps.pages_setup.outcome == 'success' }}
id: deployment
uses: actions/deploy-pages@v4

0 comments on commit 6f81f3f

Please sign in to comment.