检查链接有效性 #538
This file contains hidden or 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: 检查链接有效性 | |
| on: | |
| schedule: # 夜间执行 | |
| - cron: '0 0 * * *' | |
| workflow_dispatch: # 手动执行 | |
| pull_request: # PR执行 | |
| push: # Push到main执行 | |
| branches: | |
| - main | |
| jobs: | |
| check-url: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: 检出代码 | |
| uses: actions/[email protected] | |
| - name: 设置 Python | |
| uses: actions/setup-python@v6 | |
| with: | |
| python-version: '3.x' | |
| - name: 安装依赖 | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install -r .action_scripts/Python/requirements.txt | |
| - name: 检查链接有效性 | |
| run: python ./.action_scripts/Python/link_checker.py |