Skip to content

Commit 42c0869

Browse files
PR suggestions
1 parent e4fae10 commit 42c0869

File tree

2 files changed

+28
-12
lines changed

2 files changed

+28
-12
lines changed

.github/workflows/build.yml

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -144,22 +144,12 @@ jobs:
144144
run: make check-c-globals
145145

146146
check-c-api-docs:
147-
name: 'Check if all C APIs are documented'
148-
runs-on: ubuntu-latest
149-
timeout-minutes: 10
147+
name: C API Docs
150148
needs: build-context
151149
if: >-
152150
needs.build-context.outputs.run-tests == 'true'
153151
|| needs.build-context.outputs.run-docs == 'true'
154-
steps:
155-
- uses: actions/checkout@v4
156-
with:
157-
persist-credentials: false
158-
- uses: actions/setup-python@v5
159-
with:
160-
python-version: '3.x'
161-
- name: Check for undocumented C APIs
162-
run: python Tools/check-c-api-docs/main.py
152+
uses: ./.github/workflows/reusable-check-c-api-docs.yml
163153

164154
build-windows:
165155
name: >-
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: Reusable C API Docs Check
2+
3+
on:
4+
workflow_call:
5+
workflow_dispatch:
6+
7+
permissions:
8+
contents: read
9+
10+
env:
11+
FORCE_COLOR: 1
12+
13+
jobs:
14+
check-c-api-docs:
15+
name: 'Check if all C APIs are documented'
16+
runs-on: ubuntu-latest
17+
timeout-minutes: 5
18+
steps:
19+
- uses: actions/checkout@v4
20+
with:
21+
persist-credentials: false
22+
- uses: actions/setup-python@v5
23+
with:
24+
python-version: '3.x'
25+
- name: Check for undocumented C APIs
26+
run: python Tools/check-c-api-docs/main.py

0 commit comments

Comments
 (0)