-
Notifications
You must be signed in to change notification settings - Fork 4.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
Adding Link Check on PRs #3085
Adding Link Check on PRs #3085
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/tutorials/3085
Note: Links to docs will display an error until the docs builds have been completed. ✅ No FailuresAs of commit f7cef1f with merge base 1841346 (): This comment was automatically generated by Dr. CI and updates every 15 minutes. |
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've never used that action in the past, but if it works, this sounds great. Would be nice to test it, by adding 1-2 broken links in this PR (and than removing the change) to see that workflow will start to fail
|
||
- name: Dump all links from main | ||
id: dump_links_from_main | ||
uses: lycheeverse/lychee-action@v1 |
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.
Anything wrong with using v2
version?
uses: lycheeverse/lychee-action@v1 | |
uses: lycheeverse/lychee-action@v2 |
|
||
on: | ||
pull_request: | ||
branches: [main] |
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 limit it to a specific branch?
branches: [main] |
- name: Check out main branch | ||
run: git checkout main | ||
|
||
- name: Dump all links from main |
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.
- name: Dump all links from main | |
- name: Dump all links from ${{github.event.pull_request.base.ref}} |
- name: Check out main branch | ||
run: git checkout main |
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.
- name: Check out main branch | |
run: git checkout main | |
- name: Check out ${{github.event.pull_request.base.ref}} branch | |
run: git checkout ${{github.event.pull_request.base.ref}} |
Adding link checking on PRs. This uses lychee and the lychee action as well as code from here
Basic breakdown:
Checklist