-
Notifications
You must be signed in to change notification settings - Fork 409
51 lines (44 loc) · 1.38 KB
/
check-docs.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
# Checks that the CLI docs are up-to-date. If this fails on your PR, there may be some changes
# to the command-line docs that were not updated. Run `python docs/generate_cli_docs.py` from
# the root PySceneDetect source folder and commit the changes to resolve the issue.
name: Check Documentation
on:
schedule:
- cron: '0 0 * * *'
pull_request:
paths:
- docs/**
- scenedetect/**
push:
paths:
- docs/**
- scenedetect/**
branches:
- main
- 'releases/**'
tags:
- v*-release
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python 3.12
uses: actions/setup-python@v5
with:
python-version: '3.12'
cache: 'pip'
- name: Install Dependencies
run: |
python -m pip install --upgrade pip build wheel virtualenv
pip install -r docs/requirements.txt
pip install -r dist/requirements_windows.txt
- name: Check CLI Documentation
shell: bash
run: |
if [[ `git status --porcelain=1 | wc -l` -ne 0 ]]; then
echo "CLI documentation is of date: docs/cli.rst does not match output after running docs/generate_cli_docs.py!"
echo "Re-run `python docs/generate_cli_docs.py` to update and commit the result."
exit 1
fi