Skip to content

Commit 1478c6f

Browse files
committed
infra: add some infra
Signed-off-by: yuluo-yx <[email protected]>
1 parent 73d71a3 commit 1478c6f

File tree

22 files changed

+1804
-1420
lines changed

22 files changed

+1804
-1420
lines changed

.github/workflows/check.yaml

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
name: Hugo Docs
2+
on:
3+
push:
4+
branches:
5+
- "master"
6+
pull_request:
7+
branches:
8+
- "master"
9+
10+
permissions:
11+
contents: read
12+
13+
jobs:
14+
files-lint:
15+
runs-on: ubuntu-22.04
16+
steps:
17+
- uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4
18+
- uses: ./tools/github-actions/setup-deps
19+
- name: Setup Node
20+
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.1.0
21+
with:
22+
node-version: "21"
23+
24+
- name: Markdown Lint check
25+
run: |
26+
make lint.markdown
27+
28+
- name: Yaml Lint check
29+
run: |
30+
make lint.yaml
31+
32+
- name: Check License
33+
run: |
34+
make lint.checklicense
35+
36+
- name: Check Code Spell
37+
run: |
38+
make lint.codespell

.github/workflows/docs.yaml

Lines changed: 3 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -14,31 +14,8 @@ permissions:
1414
contents: read
1515

1616
jobs:
17-
docs-lint:
18-
runs-on: ubuntu-22.04
19-
steps:
20-
- name: Check out code
21-
uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
22-
with:
23-
ref: ${{ github.event.pull_request.head.sha }}
24-
25-
- uses: ./tools/github-actions/setup-deps
26-
27-
- name: Run markdown linter
28-
uses: nosborn/github-action-markdown-cli@9b5e871c11cc0649c5ac2526af22e23525fa344d # v3.3.0
29-
with:
30-
files: docs/site/content/*
31-
config_file: ".github/markdown_lint_config.json"
32-
33-
- name: Install linkinator
34-
run: npm install -g [email protected]
35-
36-
- name: Check links
37-
run: make docs # docs-check-links
38-
3917
docs-build:
4018
runs-on: ubuntu-latest
41-
needs: docs-lint
4219
permissions:
4320
contents: write
4421
steps:
@@ -65,7 +42,9 @@ jobs:
6542
run: |
6643
cp docs/api-testing-schema.json docs/site/static/api-testing-schema.json
6744
cp docs/api-testing-mock-schema.json docs/site/static/api-testing-mock-schema.json
68-
make docs # docs-check-links
45+
make lint.checklinks
46+
make lint.markdown
47+
make docs
6948
7049
# Upload docs for GitHub Pages
7150
- name: Upload GitHub Pages artifact

.github/workflows/license-check.yaml

Lines changed: 0 additions & 11 deletions
This file was deleted.

.licenserc.yaml

Lines changed: 0 additions & 13 deletions
This file was deleted.

checklink_config.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,4 @@
77
"aliveStatusCodes": [
88
200
99
]
10-
}
10+
}

0 commit comments

Comments
 (0)