-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fixed #2364 by adding a Github workflow for checking dead links #2406
Changes from 7 commits
0b77b69
7981c05
a63bfc4
f92b090
e26185f
ba7e77b
179cd13
5ea669d
4d9d4ec
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
name: Markdown Link Checking | ||
on: | ||
pull_request: | ||
push: | ||
branches: | ||
- "master" | ||
schedule: | ||
- cron: '0 9 */2 * *' | ||
MarcoPolo marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
jobs: | ||
check-links: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: gaurav-nelson/github-action-markdown-link-check@v1 | ||
with: | ||
use-quiet-mode: 'yes' # show only broken links | ||
use-verbose-mode: 'yes' | ||
config-file: .github/workflows/markdown-links-config.json # for removing any false positives |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
{ | ||
"ignorePatterns": [ | ||
{ | ||
"pattern": "^http://localhost" | ||
}, | ||
{ | ||
"pattern": "^https://twitter.com/" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. if we don't add this, our workflow will always fail because
My Github action was showing error like this
Details: gaurav-nelson/github-action-markdown-link-check#182 (comment) There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Twitter links are auth-walled so there's no way to check if the link works |
||
}, | ||
{ | ||
"pattern": "^https://opensource.org/" | ||
} | ||
], | ||
"aliveStatusCodes": [200], | ||
"httpHeaders": [ | ||
{ | ||
"urls": ["https://docs.github.com/"], | ||
"headers": { | ||
"Accept-Encoding": "*" | ||
} | ||
} | ||
] | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why would we want this on a schedule? Seems fine to do it on PRs. That will be more often than at 9am on the second day of the month.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I added this based on a comment from @marten-seemann on ticket.
#2364 (comment)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is there a need to revert this change ?
5ea669d