Skip to content

Commit ed0a265

Browse files
committed
Fix: Move link checker logic to pr.yaml
1 parent 9ab73ea commit ed0a265

File tree

2 files changed

+5
-8
lines changed

2 files changed

+5
-8
lines changed

.github/workflows/ci.yaml

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,6 @@ on:
44
push:
55
branches:
66
- main
7-
pull_request:
8-
branches:
9-
- main
107
workflow_dispatch:
118

129
permissions:
@@ -24,8 +21,6 @@ jobs:
2421
steps:
2522
- name: Checkout markdown
2623
uses: actions/checkout@v6.0.1
27-
with:
28-
ref: ${{ github.event.pull_request.head.sha || github.sha }}
2924

3025
- name: Link Checker
3126
uses: lycheeverse/lychee-action@v2.7.0
@@ -94,7 +89,7 @@ jobs:
9489
deploy:
9590
name: Deploy web doc
9691
runs-on: ubuntu-latest
97-
if: github.event_name == 'push' || github.event_name == 'workflow_dispatch'
92+
9893
needs: [md_linter, spell_checker]
9994
steps:
10095
- name: Checkout markdown

.github/workflows/pr.yaml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ jobs:
1414
steps:
1515
- name: Checkout markdown
1616
uses: actions/checkout@v6.0.1
17+
with:
18+
ref: ${{ github.event.pull_request.head.sha || github.sha }}
1719

1820
- name: Link Checker
1921
uses: lycheeverse/lychee-action@v2.7.0
@@ -39,7 +41,7 @@ jobs:
3941
- name: Lint markdown
4042
uses: DavidAnson/markdownlint-cli2-action@v22.0.0
4143
with:
42-
config: '.markdownlint.yaml'
44+
config: ".markdownlint.yaml"
4345
globs: |
4446
docs/**/*.md
4547
docs/*.md
@@ -81,7 +83,7 @@ jobs:
8183
- name: Set up Python
8284
uses: actions/setup-python@v6.1.0
8385
with:
84-
python-version: '3.10'
86+
python-version: "3.10"
8587

8688
- name: Install pyspelling
8789
run: |

0 commit comments

Comments
 (0)