Skip to content

Commit

Permalink
Changes to use docformatter
Browse files Browse the repository at this point in the history
  • Loading branch information
joachimmetz committed Jan 28, 2024
1 parent 8e4ce36 commit b01c75a
Show file tree
Hide file tree
Showing 9 changed files with 31 additions and 12 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/test_docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
add-apt-repository -y ppa:deadsnakes/ppa
add-apt-repository -y ppa:gift/dev
apt-get update -q
apt-get install -y build-essential git libffi-dev python${{ matrix.python-version }} python${{ matrix.python-version }}-dev python${{ matrix.python-version }}-venv libcreg-python3 libregf-python3 python3-dfdatetime python3-distutils python3-dtfabric python3-pip python3-setuptools python3-yaml
apt-get install -y build-essential git python${{ matrix.python-version }} python${{ matrix.python-version }}-dev python${{ matrix.python-version }}-venv libcreg-python3 libregf-python3 python3-dfdatetime python3-distutils python3-dtfabric python3-pip python3-setuptools python3-yaml
- name: Install tox
run: |
python3 -m pip install tox
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/test_tox.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ jobs:
add-apt-repository -y ppa:deadsnakes/ppa
add-apt-repository -y ppa:gift/dev
apt-get update -q
apt-get install -y build-essential git libffi-dev python${{ matrix.python-version }} python${{ matrix.python-version }}-dev python${{ matrix.python-version }}-venv libcreg-python3 libregf-python3 python3-dfdatetime python3-distutils python3-dtfabric python3-pip python3-setuptools python3-yaml
apt-get install -y build-essential git python${{ matrix.python-version }} python${{ matrix.python-version }}-dev python${{ matrix.python-version }}-venv libcreg-python3 libregf-python3 python3-dfdatetime python3-distutils python3-dtfabric python3-pip python3-setuptools python3-yaml
- name: Install tox
run: |
python3 -m pip install tox
Expand Down Expand Up @@ -82,7 +82,7 @@ jobs:
add-apt-repository -y ppa:deadsnakes/ppa
add-apt-repository -y ppa:gift/dev
apt-get update -q
apt-get install -y build-essential git libffi-dev python${{ matrix.python-version }} python${{ matrix.python-version }}-dev python${{ matrix.python-version }}-venv libcreg-python3 libregf-python3 python3-dfdatetime python3-distutils python3-dtfabric python3-pip python3-setuptools python3-yaml
apt-get install -y build-essential git python${{ matrix.python-version }} python${{ matrix.python-version }}-dev python${{ matrix.python-version }}-venv libcreg-python3 libregf-python3 python3-dfdatetime python3-distutils python3-dtfabric python3-pip python3-setuptools python3-yaml
- name: Install tox
run: |
python3 -m pip install tox
Expand Down Expand Up @@ -120,7 +120,7 @@ jobs:
add-apt-repository -y ppa:deadsnakes/ppa
add-apt-repository -y ppa:gift/dev
apt-get update -q
apt-get install -y build-essential git libffi-dev python${{ matrix.python-version }} python${{ matrix.python-version }}-dev python${{ matrix.python-version }}-venv libcreg-python3 libregf-python3 python3-dfdatetime python3-distutils python3-dtfabric python3-pip python3-setuptools python3-yaml
apt-get install -y build-essential git python${{ matrix.python-version }} python${{ matrix.python-version }}-dev python${{ matrix.python-version }}-venv libcreg-python3 libregf-python3 python3-dfdatetime python3-distutils python3-dtfabric python3-pip python3-setuptools python3-yaml
- name: Install tox
run: |
python3 -m pip install tox
Expand Down
4 changes: 2 additions & 2 deletions config/dpkg/changelog
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
dfwinreg (20240113-1) unstable; urgency=low
dfwinreg (20240128-1) unstable; urgency=low

* Auto-generated

-- Log2Timeline maintainers <[email protected]> Sat, 13 Jan 2024 10:06:41 +0100
-- Log2Timeline maintainers <[email protected]> Sun, 28 Jan 2024 13:09:20 +0100
6 changes: 3 additions & 3 deletions dfwinreg/__init__.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# -*- coding: utf-8 -*-
"""Digital Forensics Windows Registry (dfWinReg).
dfWinReg, or Digital Forensics Windows Registry, is a Python module
that provides read-only access to Windows Registry objects.
dfWinReg, or Digital Forensics Windows Registry, is a Python module that
provides read-only access to Windows Registry objects.
"""

__version__ = '20240113'
__version__ = '20240128'
1 change: 1 addition & 0 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@
# docstrings.
napoleon_google_docstring = True
napoleon_numpy_docstring = False
napoleon_include_init_with_doc = True
napoleon_include_private_with_doc = False
napoleon_include_special_with_doc = True

Expand Down
7 changes: 7 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
[build-system]
requires = ["setuptools", "wheel"]
build-backend = "setuptools.build_meta"

[tool.docformatter]
black = false
non-cap = ["dfDateTime", "dfImageTools", "dfVFS", "dfWinReg"]
non-strict = false
wrap-summaries = 80
wrap-descriptions = 80
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[metadata]
name = dfwinreg
version = 20240113
version = 20240128
description = Digital Forensics Windows Registry (dfWinReg).
long_description = dfWinReg, or Digital Forensics Windows Registry, provides read-only access to Windows Registry objects. The goal of dfWinReg is to provide a generic interface for accessing Windows Registry objects that resembles the Registry key hierarchy as seen on a live Windows system.
long_description_content_type = text/plain
Expand Down
13 changes: 12 additions & 1 deletion tox.ini
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[tox]
envlist = py3{7,8,9,10,11,12},coverage,docs,lint,wheel
envlist = py3{7,8,9,10,11,12},coverage,docformatter,docs,lint,wheel

[testenv]
allowlist_externals = ./run_tests.py
Expand All @@ -25,6 +25,13 @@ commands =
coverage: coverage xml
wheel: python -m build --no-isolation --wheel

[testenv:docformatter]
usedevelop = True
deps =
docformatter
commands =
docformatter --in-place --recursive dfwinreg tests

[testenv:docs]
usedevelop = True
deps =
Expand All @@ -45,10 +52,14 @@ setenv =
deps =
-rrequirements.txt
-rtest_requirements.txt
docformatter
pylint >= 3.0.0, < 3.1.0
setuptools
yamllint >= 1.26.0
commands =
docformatter --version
pylint --version
yamllint -v
docformatter --check --diff --recursive dfwinreg setup.py tests
pylint --rcfile=.pylintrc dfwinreg setup.py tests
yamllint -c .yamllint.yaml dfwinreg
2 changes: 1 addition & 1 deletion utils/update_release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ dfwinreg (${VERSION}-1) unstable; urgency=low
EOT

# Regenerate the API documentation.
tox -edocs
tox -edocformatter,docs

exit ${EXIT_SUCCESS};

0 comments on commit b01c75a

Please sign in to comment.