Add spelling version
This commit is contained in:
parent
09a3e134ea
commit
4a0dfd2890
@ -3,14 +3,17 @@
|
|||||||
|
|
||||||
# You can set these variables from the command line, and also
|
# You can set these variables from the command line, and also
|
||||||
# from the environment for the first two.
|
# from the environment for the first two.
|
||||||
SPHINXOPTS ?=
|
ALLSPHINXOPTS=-d %BUILDDIR%/doctrees %SPHINXOPTS% source
|
||||||
SPHINXBUILD ?= sphinx-build
|
SPHINXOPTS =
|
||||||
|
SPHINXBUILD = sphinx-build
|
||||||
SOURCEDIR = source
|
SOURCEDIR = source
|
||||||
BUILDDIR = build
|
BUILDDIR = build
|
||||||
|
|
||||||
|
|
||||||
# Put it first so that "make" without argument is like "make help".
|
# Put it first so that "make" without argument is like "make help".
|
||||||
help:
|
help:
|
||||||
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
|
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
|
||||||
|
@echo " spelling to check for typos in documentation"
|
||||||
|
|
||||||
.PHONY: help Makefile
|
.PHONY: help Makefile
|
||||||
|
|
||||||
@ -19,6 +22,10 @@ help:
|
|||||||
%: Makefile
|
%: Makefile
|
||||||
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
|
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
|
||||||
|
|
||||||
|
|
||||||
spelling:
|
spelling:
|
||||||
$(SPHINXBUILD) -b spelling -W $(ALLSPHINXOPTS) $(BUILDDIR)/spelling
|
$(SPHINXBUILD) -b spelling -W $(SOURCEDIR) $(BUILDDIR)/spelling
|
||||||
# $(SPHINXBUILD) -b spelling 'docs/source' 'docs/build'
|
@echo
|
||||||
|
@echo "Check finished. Wrong words can be found in " \
|
||||||
|
"build/spelling/output.txt."
|
||||||
|
|
||||||
|
@ -15,6 +15,7 @@ import sys
|
|||||||
import importlib
|
import importlib
|
||||||
import inspect
|
import inspect
|
||||||
import enchant
|
import enchant
|
||||||
|
from enchant import checker
|
||||||
|
|
||||||
|
|
||||||
sys.path.insert(0, os.path.abspath('../../'))
|
sys.path.insert(0, os.path.abspath('../../'))
|
||||||
@ -114,12 +115,24 @@ def skip_queryset(app, what, name, obj, skip, options):
|
|||||||
return True
|
return True
|
||||||
return skip
|
return skip
|
||||||
|
|
||||||
|
# def process_signature(app):
|
||||||
|
# if app != 'module':
|
||||||
|
# return lines
|
||||||
|
# from enchant.checker import SpellChecker
|
||||||
|
# for line in lines:
|
||||||
|
# chkr = SpellChecker("ru_RU", line)
|
||||||
|
# for err in chkr:
|
||||||
|
# print(err)
|
||||||
|
# print('cheked')
|
||||||
|
|
||||||
|
|
||||||
def setup(app):
|
def setup(app):
|
||||||
# Register the docstring processor with sphinx
|
# Register the docstring processor with sphinx
|
||||||
app.connect('autodoc-process-docstring', process_django_models)
|
app.connect('autodoc-process-docstring', process_django_models)
|
||||||
app.connect('autodoc-skip-member', skip_queryset)
|
app.connect('autodoc-skip-member', skip_queryset)
|
||||||
app.connect('autodoc-process-docstring', process_modules)
|
app.connect('autodoc-process-docstring', process_modules)
|
||||||
|
# process_signature(app)
|
||||||
|
print('app')
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -183,10 +196,12 @@ intersphinx_mapping = {
|
|||||||
autodoc_default_flags = ['members']
|
autodoc_default_flags = ['members']
|
||||||
|
|
||||||
# spell checking
|
# spell checking
|
||||||
print(enchant.list_languages())
|
|
||||||
|
|
||||||
|
|
||||||
spelling_lang = 'ru_RU'
|
spelling_lang = 'ru_RU'
|
||||||
tokenizer_lang = 'ru_RU'
|
tokenizer_lang = 'ru_RU'
|
||||||
spelling_word_list_filename = ['spelling_wordlist.txt', 'another_list.txt']
|
spelling_word_list_filename = ['spelling_wordlist', None]
|
||||||
spelling_exclude_patterns=['ignored_*']
|
spelling_exclude_patterns=['ignored_*']
|
||||||
spelling_show_suggestions = True
|
spelling_show_suggestions = True
|
||||||
spelling_show_whole_line=True
|
spelling_show_whole_line=True
|
||||||
|
@ -30,8 +30,7 @@
|
|||||||
**После авторизации пользователь может выбрать из следующих разделов меню:**
|
**После авторизации пользователь может выбрать из следующих разделов меню:**
|
||||||
|
|
||||||
* **"Профиль"** - просмотреть свои данные и запросить права доступа
|
* **"Профиль"** - просмотреть свои данные и запросить права доступа
|
||||||
* **"Запрос прав"** - получение прав для работы с тикетами или
|
* **"Запрос прав"** - получение прав для работы с тикетами или **"Управление"** - доступно для администратора и предоставляет возможность группового назначения ролей пользователям
|
||||||
**"Управление"** - доступно для администратора и предоставляет возможность группового назначения ролей пользователям
|
|
||||||
|
|
||||||
.. image:: _static/main_logined_agent.png
|
.. image:: _static/main_logined_agent.png
|
||||||
|
|
||||||
|
0
docs/source/spelling_wordlist.txt
Normal file
0
docs/source/spelling_wordlist.txt
Normal file
Loading…
x
Reference in New Issue
Block a user