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
35 changes: 35 additions & 0 deletions .github/workflows/ci-developer-hub-links.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: Check developer-hub links

on:
pull_request:
paths:
- "apps/developer-hub/content/**"
- "apps/developer-hub/src/**"
- .github/workflows/ci-developer-hub-links.yml
- .lycheeignore
push:
branches: [main]
paths:
- "apps/developer-hub/content/**"
- "apps/developer-hub/src/**"

concurrency:
group: links-${{ github.head_ref || github.run_id }}
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Scope concurrency group to PR identity

The concurrency key uses github.head_ref, which is only the source branch name, so different pull requests that happen to use the same branch name (for example patch-1 from different forks) will share one group and cancel each other’s runs. This means link checks can be terminated for unrelated PRs, leaving missing or flaky status checks; use a PR-unique value like github.event.pull_request.number (with a push fallback) to ensure cancellation only affects stale runs of the same PR.

Useful? React with 👍 / 👎.

cancel-in-progress: true

jobs:
check-links:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Check links
uses: lycheeverse/lychee-action@v2
with:
args: >-
--base https://docs.pyth.network
--no-progress
--exclude-path apps/developer-hub/node_modules
'apps/developer-hub/content/**/*.mdx'
'apps/developer-hub/content/**/*.md'
fail: true
10 changes: 10 additions & 0 deletions .lycheeignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# Placeholder / example URLs in code snippets
YOUR_
REPLACE_
example\.com

# Blockchain explorer links with placeholder addresses
0xYOUR

# RPC / API endpoints that require auth or may rate-limit
https://hermes\.pyth\.network/docs/openapi\.json
Loading