Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Feb 20, 2024
1 parent e6b5837 commit 5b8c50a
Show file tree
Hide file tree
Showing 24 changed files with 28 additions and 6 deletions.
8 changes: 4 additions & 4 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,15 +42,15 @@ repos:

# ruff - python linter with fixing ability
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: cc575a3e5800b42ffbb5182b53d87203b2c4fc26 # frozen: v0.2.2
rev: cc575a3e5800b42ffbb5182b53d87203b2c4fc26 # frozen: v0.2.2
hooks:
- id: ruff
name: ruff (fix)
args: ["--fix-only", "--exit-non-zero-on-fix", "--config=pyproject.toml"]

# black - python formatter
- repo: https://github.com/psf/black
rev: 6fdf8a4af28071ed1d079c01122b34c5d587207a # frozen: 24.2.0
rev: 6fdf8a4af28071ed1d079c01122b34c5d587207a # frozen: 24.2.0
hooks:
- id: black
args: ["--safe"]
Expand Down Expand Up @@ -142,7 +142,7 @@ repos:

# ruff - python linter with fixing ability
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: cc575a3e5800b42ffbb5182b53d87203b2c4fc26 # frozen: v0.2.2
rev: cc575a3e5800b42ffbb5182b53d87203b2c4fc26 # frozen: v0.2.2
hooks:
- id: ruff
name: ruff (lint)
Expand Down Expand Up @@ -228,6 +228,6 @@ repos:

# yamllint - yaml linter
- repo: https://github.com/adrienverge/yamllint
rev: 81e9f98ffd059efe8aa9c1b1a42e5cce61b640c6 # frozen: v1.35.1
rev: 81e9f98ffd059efe8aa9c1b1a42e5cce61b640c6 # frozen: v1.35.1
hooks:
- id: yamllint
1 change: 1 addition & 0 deletions docs/source/conf.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Configuration file for the Sphinx documentation builder."""

from __future__ import annotations

import datetime
Expand Down
1 change: 1 addition & 0 deletions prep_release.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Script for preparing the repo for a new release."""

from __future__ import annotations

import argparse
Expand Down
1 change: 1 addition & 0 deletions src/rstcheck_core/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Rstcheck package."""

from __future__ import annotations

import logging
Expand Down
1 change: 1 addition & 0 deletions src/rstcheck_core/_docutils.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Docutils helper functions."""

from __future__ import annotations

import importlib
Expand Down
1 change: 1 addition & 0 deletions src/rstcheck_core/_extras.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ def print_sphinx_version():
_extras.install_guard("sphinx")
print(sphinx.version_info)
"""

from __future__ import annotations

import importlib
Expand Down
1 change: 1 addition & 0 deletions src/rstcheck_core/_sphinx.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Sphinx helper functions."""

from __future__ import annotations

import contextlib
Expand Down
1 change: 1 addition & 0 deletions src/rstcheck_core/checker.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Checking functionality."""

from __future__ import annotations

import contextlib
Expand Down
1 change: 1 addition & 0 deletions src/rstcheck_core/config.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Rstcheck configuration functionality."""

from __future__ import annotations

import configparser
Expand Down
1 change: 1 addition & 0 deletions src/rstcheck_core/inline_config.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Inline config comment functionality."""

from __future__ import annotations

import functools
Expand Down
1 change: 1 addition & 0 deletions src/rstcheck_core/runner.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Runner of rstcheck_core."""

from __future__ import annotations

import logging
Expand Down
1 change: 1 addition & 0 deletions src/rstcheck_core/types.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Helper types."""

from __future__ import annotations

import pathlib
Expand Down
1 change: 1 addition & 0 deletions tests/_docutils_test.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Tests for ``_docutils`` module."""

from __future__ import annotations

import docutils.parsers.rst.directives as docutils_directives
Expand Down
1 change: 1 addition & 0 deletions tests/_extras_test.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Tests for ``_extras`` module."""

from __future__ import annotations

import importlib.metadata
Expand Down
1 change: 1 addition & 0 deletions tests/_sphinx_test.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Tests for ``_sphinx`` module."""

from __future__ import annotations

import typing as t
Expand Down
1 change: 1 addition & 0 deletions tests/checker_test.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Tests for ``checker`` module."""

from __future__ import annotations

import os
Expand Down
1 change: 1 addition & 0 deletions tests/config_test.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Tests for ``config`` module."""

from __future__ import annotations

import logging
Expand Down
1 change: 1 addition & 0 deletions tests/conftest.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Fixtures for tests."""

from __future__ import annotations

import pathlib
Expand Down
4 changes: 2 additions & 2 deletions tests/inline_config_test.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Tests for ``inline_config`` module."""

from __future__ import annotations

import typing as t
Expand Down Expand Up @@ -212,8 +213,7 @@ def __call__( # noqa: D102
source: str,
source_origin: types.SourceFileOrString,
warn_unknown_settings: bool = False, # noqa: FBT002
) -> t.Generator[str, None, None]:
...
) -> t.Generator[str, None, None]: ...


class TestFindIgnoredFunctions:
Expand Down
1 change: 1 addition & 0 deletions tests/integration_tests/conftest.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Fixtures for integration tests."""

from __future__ import annotations

import re
Expand Down
1 change: 1 addition & 0 deletions tests/integration_tests/file_checker_test.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Integration test for the main runner."""

from __future__ import annotations

import io
Expand Down
1 change: 1 addition & 0 deletions tests/integration_tests/runner_test.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Integration test for the main runner."""

from __future__ import annotations

import io
Expand Down
1 change: 1 addition & 0 deletions tests/runner_test.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Tests for ``runner`` module."""

from __future__ import annotations

import contextlib
Expand Down
1 change: 1 addition & 0 deletions tests/types_test.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Tests for ``types`` module."""

from __future__ import annotations

import re
Expand Down

0 comments on commit 5b8c50a

Please sign in to comment.