GitAuto: [FEATURE] Add support to PIP/PyPI
- Python
#2496
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: Link checker | |
on: | |
workflow_dispatch: | |
pull_request: | |
push: | |
branches: | |
- main | |
schedule: | |
- cron: 0 0 * * 0 | |
concurrency: | |
group: links-checker | |
cancel-in-progress: true | |
jobs: | |
link-checker: | |
runs-on: ubuntu-latest | |
permissions: | |
issues: write | |
contents: read | |
pull-requests: write | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Restore lychee cache | |
uses: actions/cache@v4 | |
with: | |
path: .lycheecache | |
key: cache-lychee-${{ github.sha }} | |
restore-keys: cache-lychee- | |
- name: Attach WireGuard connection | |
shell: bash | |
run: | | |
sudo apt install resolvconf | |
sudo apt install wireguard | |
echo "${{ secrets.WIREGUARD_CONFIG }}" > wg0.conf | |
sudo chmod 600 wg0.conf | |
sudo wg-quick up ./wg0.conf | |
- name: Run lychee | |
uses: lycheeverse/[email protected] | |
id: lychee | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
args: "--base . --cache --max-cache-age 1d ." | |
- name: Detach WireGuard connection | |
shell: bash | |
if: always() | |
run: sudo wg-quick down ./wg0.conf | |
- name: Create issue | |
if: github.event_name != 'pull_request' && env.lychee_exit_code != 0 | |
uses: peter-evans/create-issue-from-file@v5 | |
with: | |
title: πβ Link checker report | |
labels: | | |
π bug | |
π link checker | |
good first issue | |
help wanted | |
hacktoberfest | |
content-filepath: ./lychee/out.md | |
- name: Update PR with comment | |
uses: mshick/add-pr-comment@v2 | |
if: github.event_name == 'pull_request' && env.lychee_exit_code != 0 | |
with: | |
refresh-message-position: true | |
message-id: 'link-checker-result' | |
message-path: ./lychee/out.md |