File: linkcheck.yml

package info (click to toggle)
python-pyvista 0.46.4-4
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 176,968 kB
  • sloc: python: 94,346; sh: 216; makefile: 70
file content (68 lines) | stat: -rw-r--r-- 1,761 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
# Reference:
#   - https://github.com/actions/cache
#   - https://github.com/actions/checkout
#   - https://github.com/lycheeverse/lychee-action
#   - https://github.com/peter-evans/create-issue-from-file

name: LinkCheck - All files 🔗

on:
  schedule:
    - cron: "0 5 * * 0" # Runs at 05:00 on Sunday.
  workflow_dispatch:

concurrency:
  group: ${{ github.workflow }}-${{ github.ref }}
  cancel-in-progress: true

defaults:
  run:
    shell: bash -l {0}

jobs:
  linkcheck:
    runs-on: "ubuntu-22.04"

    permissions:
      issues: write # required for peter-evans/create-issue-from-file

    steps:
      - uses: actions/checkout@v4
        with:
          fetch-depth: 0
          persist-credentials: false

      - name: "Cache Lychee"
        uses: actions/cache@v4
        with:
          path: .lycheecache
          key: cache-lychee

      - name: "Run Lychee"
        id: lychee
        uses: lycheeverse/lychee-action@82202e5e9c2f4ef1a55a3d02563e1cb6041e5332
        with:
          args: >
            --cache
            --no-progress
            --verbose
            './doc/source/**/*.md'
            './doc/source/**/*.rst'
            './doc/source/**/*.txt'
            './pyvista/**/*.py'
            './examples/**/*.py'
            './examples_trame/**/*.py'
          fail: false

      - name: "Report Failure"
        if: steps.lychee.outputs.exit_code != 0
        uses: peter-evans/create-issue-from-file@e8ef132d6df98ed982188e460ebb3b5d4ef3a9cd
        with:
          title: "chore: linkcheck failure"
          content-filepath: ./lychee/out.md
          labels: |
            documentation

      - name: "Exit Action"
        if: steps.lychee.outputs.exit_code != 0
        run: exit {{ steps.lychee.outputs.exit_code }}