- name: Generate redirects
run: python scripts/gen_redirect.py
- name: Deploy to gh-pages
- if: ${{ github.event_name == push }}
+ if: ${{ github.event_name == 'push' }}
uses: peaceiris/actions-gh-pages@v3
with:
- - github_token: ${{ secrets.GITHUB_TOKEN }}
- - publish_dir: ./site
+ github_token: ${{ secrets.GITHUB_TOKEN }}
+ publish_dir: ./site
+ force_orphan: true
- name: BaiduPusher
- if: ${{ github.event_name == push && env.BaiduToken }}
+ if: ${{ github.event_name == 'push' && env.BaiduToken }}
run: chmod +x scripts/BaiduPusher.sh && ./scripts/BaiduPusher.sh