Skip to content

Commit b739c3a

Browse files
authored
ci: update global workflows (#257)
1 parent 2e98c7b commit b739c3a

File tree

2 files changed

+46
-0
lines changed

2 files changed

+46
-0
lines changed

.github/workflows/link-check-cron.yml

+29
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: Check Markdown links (Weekly)
2+
3+
on:
4+
workflow_dispatch:
5+
schedule:
6+
# At 00:00 UTC on every Monday
7+
- cron: '0 0 * * 0'
8+
9+
jobs:
10+
External-link-validation-weekly:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v3
14+
15+
# Checks the status of hyperlinks in .md files
16+
- name: Check links
17+
uses: gaurav-nelson/github-action-markdown-link-check@v1
18+
with:
19+
use-quiet-mode: 'yes'
20+
use-verbose-mode: 'yes'
21+
22+
- name: Report workflow run status to Slack
23+
uses: 8398a7/action-slack@v3
24+
with:
25+
status: ${{ job.status }}
26+
fields: repo,message,action,eventName,ref,workflow
27+
env:
28+
SLACK_DOCS_CHANNEL: ${{ secrets.SLACK_DOCS_CHANNEL }}
29+
if: failure() # Only, on failure, send a message on the Slack Docs Channel (if there are broken links)

.github/workflows/link-check-pr.yml

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
name: Check Markdown links
2+
3+
on:
4+
pull_request_target:
5+
types: [synchronize, ready_for_review, opened, reopened]
6+
7+
jobs:
8+
External-link-validation-on-PR:
9+
runs-on: ubuntu-latest
10+
steps:
11+
- uses: actions/checkout@v3
12+
- name: Check links
13+
uses: gaurav-nelson/github-action-markdown-link-check@v1
14+
with:
15+
use-quiet-mode: 'yes'
16+
use-verbose-mode: 'yes'
17+
check-modified-files-only: 'yes' #Only modified files are checked on PRs

0 commit comments

Comments
 (0)