chore: 内部获取文件名后缀方法调整 #216
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build and Deploy Docs | |
on: | |
push: | |
branches: | |
- master | |
tags-ignore: | |
- v* | |
pull_request: | |
branches: | |
- master | |
jobs: | |
build-and-deploy: | |
runs-on: ubuntu-latest | |
environment: github-pages | |
steps: | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: 20 | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- uses: pnpm/action-setup@v2 | |
with: | |
version: 8 | |
- name: Install | |
run: pnpm install | |
- name: Test | |
run: pnpm test:coverage && ls ./coverage/ | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v3 | |
with: | |
token: ${{ secrets.CODECOV_TOKEN }} | |
- name: Build docs | |
run: pnpm build:doc | |
- name: Deploy | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
github_token: ${{ secrets.ACCESS_TOKEN_WORKFLOW }} | |
publish_dir: docs |