forked from python/python-docs-fa
-
Notifications
You must be signed in to change notification settings - Fork 0
61 lines (49 loc) · 1.52 KB
/
Copy pathlint.yml
File metadata and controls
61 lines (49 loc) · 1.52 KB
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
52
53
54
55
56
57
58
59
60
61
name: Lint Check
on:
schedule:
- cron: '0 0 * * *'
push:
branches:
- '*'
pull_request:
branches:
- '*'
workflow_dispatch:
jobs:
lint:
runs-on: ubuntu-latest
steps:
- name: Checkout CPython docs
uses: actions/checkout@v4
with:
repository: python/cpython
ref: v3.14.6
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.12'
- name: Install sphinx-lint and polib
run: pip install sphinx-lint polib
- name: Install gettext tools
run: sudo apt-get install -y gettext
- name: Setup virtual environment
run: make venv
working-directory: ./Doc
- name: Checkout translation files
uses: actions/checkout@v4
with:
path: Doc/locales/fa/LC_MESSAGES
- name: Setup problem matcher
uses: rffontenelle/sphinx-lint-problem-matcher@v1.0.0
- name: Run sphinx-lint
run: sphinx-lint
working-directory: Doc/locales/fa/LC_MESSAGES
- name: Check PO file validity
run: find . -name '*.po' -exec msgfmt --check {} \;
working-directory: Doc/locales/fa/LC_MESSAGES
- name: Check markup preservation
run: python3 scripts/check_markup.py .
working-directory: Doc/locales/fa/LC_MESSAGES
- name: Build documentation
run: make -e SPHINXOPTS="--color -D language='fa' -D gettext_allow_fuzzy_translations=1 -W --keep-going" html
working-directory: ./Doc