Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions .github/workflows/linkcheck.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: Linkcheck
on:
schedule:
- cron: '0 6 * * 1'
pull_request:
paths:
- 'docs/**'
workflow_dispatch: {}

jobs:
linkcheck:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: dtcenter/metplus-action-linkcheck@v1
with:
fail-on-broken-links: 'true'
upload-artifact: 'true'
20 changes: 20 additions & 0 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -262,6 +262,26 @@
'figure': 'Figure %s',
}

# -- linkcheck builder configuration ----------------------------------
# https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-the-linkcheck-builder

linkcheck_timeout = 10
linkcheck_retries = 2
linkcheck_workers = 8

linkcheck_ignore = [
# add regex patterns for URLs that should be skipped, e.g.:
# r'https://dtcenter\.org/.*', # if this site blocks automated requests
# r'https://.*metexpress.*\.gsl\.noaa\.gov/.*', # live demo instance; may be internal-network-only
]

linkcheck_allowed_redirects = {
# map of regex -> regex for redirects that are fine to follow
}

linkcheck_anchors = True
linkcheck_anchors_ignore = ['^!']

# -- Export variables --------------------------------------------------------

rst_epilog = """
Expand Down
Loading