Skip to content

Commit c1b6d4b

Browse files
Updated files with 'repo_helper'. (#79)
Co-authored-by: repo-helper[bot] <74742576+repo-helper[bot]@users.noreply.github.com>
1 parent 10deedb commit c1b6d4b

File tree

4 files changed

+16
-5
lines changed

4 files changed

+16
-5
lines changed

.pre-commit-config.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ exclude: ^domdf_python_tools/compat/importlib_resources.py$
55

66
repos:
77
- repo: https://github.com/repo-helper/pyproject-parser
8-
rev: v0.5.0
8+
rev: v0.6.1
99
hooks:
1010
- id: reformat-pyproject
1111

@@ -67,7 +67,7 @@ repos:
6767
- --keep-runtime-typing
6868

6969
- repo: https://github.com/Lucas-C/pre-commit-hooks
70-
rev: v1.1.13
70+
rev: v1.2.0
7171
hooks:
7272
- id: remove-crlf
7373
- id: forbid-crlf

doc-source/conf.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,8 @@
3232
slug = re.sub(r'\W+', '-', project.lower())
3333
release = version = config.version
3434

35-
todo_include_todos = bool(os.environ.get("SHOW_TODOS", 0))
35+
sphinx_builder = os.environ.get("SPHINX_BUILDER", "html").lower()
36+
todo_include_todos = int(os.environ.get("SHOW_TODOS", 0)) and sphinx_builder != "latex"
3637

3738
intersphinx_mapping = {
3839
"python": ("https://docs.python.org/3/", None),

justfile

+1-2
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,7 @@ unused-imports:
1010
tox -e lint -- --select F401
1111

1212
incomplete-defs:
13-
#!/usr/bin/env bash
14-
tox -e mypy -- --disallow-incomplete-defs --disallow-untyped-defs | grep "Function is missing a .* annotation" || exit 0
13+
tox -e lint -- --select MAN
1514

1615
vdiff:
1716
git diff $(repo-helper show version -q)..HEAD

tox.ini

+11
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
# * testenv:docs
66
# * testenv:build
77
# * testenv:lint
8+
# * testenv:perflint
89
# * testenv:mypy
910
# * testenv:pyup
1011
# * testenv:coverage
@@ -51,6 +52,7 @@ cov = py36, coverage
5152

5253
[testenv:docs]
5354
setenv = SHOW_TODOS = 1
55+
passenv = SPHINX_BUILDER
5456
basepython = python3.8
5557
changedir = {toxinidir}/doc-source
5658
extras = all
@@ -93,11 +95,20 @@ deps =
9395
git+https://github.com/domdfcoding/flake8-rst-docstrings-sphinx.git
9496
git+https://github.com/domdfcoding/flake8-rst-docstrings.git
9597
git+https://github.com/python-formate/flake8-unused-arguments.git@magic-methods
98+
git+https://github.com/python-formate/flake8-missing-annotations.git
9699
pydocstyle>=6.0.0
97100
pygments>=2.7.1
98101
importlib_metadata<4.5.0; python_version<'3.8'
99102
commands = python3 -m flake8_rst_docstrings_sphinx domdf_python_tools tests --allow-toolbox {posargs}
100103

104+
[testenv:perflint]
105+
basepython = python3.6
106+
changedir = {toxinidir}
107+
ignore_errors = True
108+
skip_install = True
109+
deps = perflint
110+
commands = python3 -m perflint domdf_python_tools {posargs}
111+
101112
[testenv:mypy]
102113
basepython = python3.6
103114
ignore_errors = True

0 commit comments

Comments
 (0)