mirror of
https://github.com/inventree/inventree-docs.git
synced 2025-04-26 20:56:51 +00:00
Add a .github workflow to check that "strict" mode is always set
This commit is contained in:
parent
191ca07207
commit
f39c54be8d
26
.github/workflows/check_config.yaml
vendored
Normal file
26
.github/workflows/check_config.yaml
vendored
Normal file
@ -0,0 +1,26 @@
|
||||
name: Config Checks
|
||||
|
||||
on:
|
||||
push:
|
||||
branches-ignore:
|
||||
- l10*
|
||||
|
||||
pull_request:
|
||||
branches-ignore:
|
||||
- l10*
|
||||
|
||||
jobs:
|
||||
|
||||
mkdocs:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout Code
|
||||
uses: actions/checkout@v2
|
||||
- name: Setup Python
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: 3.7
|
||||
- name: Run Checks
|
||||
run: |
|
||||
|
13
ci/check_mkdocs_config.py
Normal file
13
ci/check_mkdocs_config.py
Normal file
@ -0,0 +1,13 @@
|
||||
import os
|
||||
import yaml
|
||||
|
||||
here = os.path.dirname(__file__)
|
||||
|
||||
tld = os.path.abspath(os.path.join(here, '..'))
|
||||
|
||||
config_file = os.path.join(tld, 'mkdocs.yml')
|
||||
|
||||
with open(config_file, 'r') as f:
|
||||
data = yaml.safe_load(f)
|
||||
|
||||
assert data['strict'] == True
|
Loading…
x
Reference in New Issue
Block a user