Compare commits

...

85 Commits
v3.1.3 ... main

Author SHA1 Message Date
renovate[bot] 84fdc06315
chore(deps): lock file maintenance (#695)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-05-15 11:06:23 +02:00
renovate[bot] db68e80372
chore(deps): update quay.io/thegeeklab/hugo docker tag to v0.125.7 (#696)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-05-14 14:24:17 +02:00
renovate[bot] af702628eb chore(deps): update dependency ruff to v0.4.4 2024-05-13 03:05:31 +02:00
renovate[bot] 81d4e97af6
fix(deps): update dependency jinja2 to v3.1.4 (#692)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-05-06 21:29:22 +02:00
renovate[bot] a33f3c53bb chore(deps): update dependency ruff to v0.4.3 2024-05-06 02:37:46 +02:00
renovate[bot] ccc2d249f8
fix(deps): update dependency jsonschema to v4.22.0 (#689)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-05-01 12:36:45 +02:00
renovate[bot] f7ff5fd624
chore(deps): lock file maintenance (#683)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-29 10:28:49 +02:00
renovate[bot] acee6e1285 chore(deps): update devdeps non-major 2024-04-29 04:15:22 +02:00
Julien Rottenberg 2375ad118d
fix: install extra group when using pre-commit (#687) 2024-04-24 08:54:48 +02:00
renovate[bot] a2f02527d9
fix(deps): update dependency ansible-core to v2.14.16 (#686)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-23 21:18:13 +02:00
renovate[bot] 0bf59ac34f chore(deps): update dependency ruff to v0.4.1 2024-04-22 03:46:05 +02:00
renovate[bot] 94ec1a632b chore(deps): update dependency ruff to v0.3.7 2024-04-15 02:40:29 +02:00
renovate[bot] 075e1f91ca
fix(deps): update dependency ansible-core to v2.14.15 (#681)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-12 09:59:00 +02:00
Robert Kaussow 4cf63bf2fe
separate minor-patch for ansible deps 2024-04-12 09:23:00 +02:00
renovate[bot] e3f797d5e3
chore(deps): lock file maintenance (#677)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-12 09:18:07 +02:00
renovate[bot] 3a0c5ae35f chore(docker): update python:3.12-alpine docker digest to ef09762 2024-04-11 04:03:51 +02:00
renovate[bot] 9f7f943c93 chore(deps): update dependency ruff to v0.3.5 2024-04-08 03:24:24 +02:00
renovate[bot] b38c4aa2b8 chore(deps): update dependency thegeeklab/hugo-geekdoc to v0.45.0 2024-04-08 03:24:09 +02:00
renovate[bot] ed167d1443 chore(deps): update dependency thegeeklab/hugo-geekdoc to v0.44.3 2024-04-01 03:24:41 +02:00
renovate[bot] da6fd26c6d
chore(deps): update quay.io/thegeeklab/wp-docker-buildx docker tag to v4 (#674)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-03-27 08:42:10 +01:00
renovate[bot] 522c21f8fc chore(docker): update python:3.12-alpine docker digest to c7eb5c9 2024-03-27 01:21:36 +01:00
renovate[bot] 28e39055e3
chore(deps): lock file maintenance (#669)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-03-26 21:39:41 +01:00
renovate[bot] 894965286b
chore(deps): update dependency pytest-cov to v5 (#671)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-03-25 08:34:20 +01:00
renovate[bot] c2e0f787ce chore(deps): update devdeps non-major 2024-03-25 01:35:05 +01:00
renovate[bot] d524537fd3
chore(deps): update quay.io/thegeeklab/hugo docker tag to v0.124.1 (#670)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-03-21 08:48:14 +01:00
renovate[bot] a559b654ca chore(deps): update dependency ruff to v0.3.3 2024-03-18 03:00:26 +01:00
renovate[bot] aa78adf912 chore(docker): update python:3.12-alpine docker digest to 25a82f6 2024-03-17 01:49:43 +01:00
Robert Kaussow 6e88c18375
ci: fix deprecated ruff command 2024-03-12 20:52:52 +01:00
Robert Kaussow 7b9ba09f1d fix linting 2024-03-11 09:44:16 +01:00
renovate[bot] 08883952c1 chore(deps): update devdeps non-major 2024-03-11 09:44:16 +01:00
renovate[bot] e1ef4937dd chore(deps): update dependency thegeeklab/hugo-geekdoc to v0.44.2 2024-03-11 02:43:51 +01:00
renovate[bot] 571222f6f5
chore(deps): lock file maintenance (#663)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-03-07 11:04:59 +01:00
renovate[bot] 6d50525021
fix(deps): update dependency environs to v11 (#664)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-03-07 11:04:46 +01:00
renovate[bot] 3ade4698e7 chore(deps): update devdeps non-major 2024-03-04 02:18:33 +01:00
renovate[bot] ee81c8ee73
chore(deps): lock file maintenance (#659)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-02-26 10:26:11 +01:00
renovate[bot] 03df5bd79b
chore(deps): lock file maintenance (#657)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-02-26 10:14:18 +01:00
renovate[bot] 1e32a8f87a chore(deps): update dependency pytest to v8.0.2 2024-02-26 02:21:25 +01:00
renovate[bot] dab9bc8691 chore(deps): update devdeps non-major 2024-02-19 02:20:31 +01:00
Robert Kaussow e2eaa81c4f
[skip ci] revert renovate automerge config 2024-02-15 12:23:07 +01:00
renovate[bot] 732f588aa9
chore(deps): update quay.io/thegeeklab/hugo docker tag to v0.122.0 (#655)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-02-11 16:53:09 +01:00
Robert Kaussow 6619351fbd
enable renovate on automerge branches 2024-02-09 23:08:29 +01:00
renovate[bot] 8f6f444931 chore(docker): update python:3.12-alpine docker digest to 1a05012 2024-02-09 05:43:21 +01:00
renovate[bot] 49b861cabc
fix(deps): update dependency ruamel.yaml to v0.18.6 (#653)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-02-07 22:36:59 +01:00
renovate[bot] 59b497d745
fix(deps): update dependency ansible-core to v2.14.14 (#652)
This CVE does not affect ansible-doctor and is therefore not treated as a security update.

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-02-07 08:38:43 +01:00
Robert Kaussow b2f4fd2bd8
chore: bump ruff to v0.2.1 (#651) 2024-02-06 09:34:17 +01:00
renovate[bot] 864af95606
chore(deps): update dependency pytest to v8 (#648)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-31 09:05:49 +01:00
renovate[bot] 758c87ee80 chore(docker): update python:3.12-alpine docker digest to 14cfc61 2024-01-29 06:35:05 +01:00
renovate[bot] 9b0edda70a
chore(deps): update quay.io/thegeeklab/wp-docker-buildx docker tag to v3 (#647)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-22 11:27:39 +01:00
renovate[bot] 1d32f7548a chore(deps): update dependency ruff to v0.1.14 2024-01-22 02:14:07 +01:00
renovate[bot] 704cdb9d7c
fix(deps): update dependency jsonschema to v4.21.1 (#645)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-20 15:13:09 +01:00
renovate[bot] c7f3fe57a0 chore(docker): update python:3.12-alpine docker digest to 801b54e 2024-01-19 23:32:46 +01:00
renovate[bot] 1270d7cb7d chore(docker): update python:3.12-alpine docker digest to 4a156f7 2024-01-19 05:23:41 +01:00
renovate[bot] 461eeb2d74 chore(docker): update python:3.12-alpine docker digest to 67990ec 2024-01-19 02:54:58 +01:00
renovate[bot] 0817646004
fix(deps): update dependency jsonschema to v4.21.0 (#641)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-18 10:21:51 +01:00
renovate[bot] 5242fd882a chore(deps): update dependency thegeeklab/hugo-geekdoc to v0.44.1 2024-01-16 00:19:56 +01:00
renovate[bot] 052c668d92
fix(deps): update dependency anyconfig to v0.14.0 (#638)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-15 21:56:46 +01:00
Robert Kaussow 1e8a8beef7 fix linting 2024-01-15 15:24:52 +01:00
renovate[bot] c124460c11 chore(deps): update dependency ruff to v0.1.13 2024-01-15 15:24:52 +01:00
renovate[bot] 38bd53f7bc
fix(deps): update dependency environs to v10.3.0 (#637)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-12 08:30:19 +01:00
renovate[bot] dbf9c979ac
fix(deps): update dependency jinja2 to v3.1.3 (#636)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-11 08:29:35 +01:00
renovate[bot] fe12548387
fix(deps): update dependency ansible-core to v2.14.12 [security] (#633)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-10 10:09:14 +01:00
Robert Kaussow ae14704b74
chore: drop support for python 3.8 (#634)
BREAKING CHANGE: The support for python 3.8 was removed to bundle `ansible-core` v2.14.x by default.
2024-01-10 09:07:45 +01:00
renovate[bot] 2232a12bc8
fix(deps): update dependency environs to v10.2.0 (#632)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-10 08:48:16 +01:00
Robert Kaussow 78d4c5f44b
fix: make `ansible-core` an optional extra-dependency (#631) 2024-01-10 08:32:57 +01:00
Robert Kaussow c3068a573f
re-generate poetry lockfile 2024-01-09 15:27:07 +01:00
danielpodwysocki 505f9b58cc
fix: allow ansible-core versions newer than 2.13
ansible-core 2.13 and the corresponding ansible 6.0.0 had been deprecated. This allows users to use ansible-doctor with any modern enough version of ansible, while not breaking legacy setups.
2024-01-09 15:19:10 +01:00
renovate[bot] 593df92d32
chore(deps): lock file maintenance (#618)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-09 15:17:43 +01:00
renovate[bot] 568b91654d
fix(deps): update dependency environs to v10.1.0 (#627)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-09 15:03:32 +01:00
renovate[bot] 4afabc4284 chore(deps): update dependency ruff to v0.1.11 2024-01-08 02:07:30 +01:00
renovate[bot] 10ff283ec2
chore(deps): update quay.io/thegeeklab/hugo docker tag to v0.121.2 (#625)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-07 20:42:02 +01:00
renovate[bot] 1d0ff92bf3 chore(deps): update dependency pytest to v7.4.4 2024-01-01 03:06:14 +01:00
renovate[bot] 7245a4149c
fix(deps): update dependency environs to v10 (#616)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-12-27 11:07:48 +01:00
renovate[bot] df155dcf8a chore(deps): update dependency ruff to v0.1.9 2023-12-25 01:59:40 +01:00
Robert Kaussow 2ce29b2bff
use exact package name match 2023-12-24 00:01:40 +01:00
Robert Kaussow 1dc53d1970
disable renovate for python test matrix in ci 2023-12-23 23:40:38 +01:00
Robert Kaussow 2f1f42318b
use list style synatx and cleanup (#619) 2023-12-23 23:24:56 +01:00
renovate[bot] 69d682df79 chore(deps): update dependency ruff to v0.1.8 2023-12-18 02:34:28 +01:00
Robert Kaussow 223b1d8814
cleanup unused env vars in ci 2023-12-17 14:07:58 +01:00
renovate[bot] 70539cc9a2
chore(deps): lock file maintenance (#615)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-12-12 08:55:43 +01:00
renovate[bot] 982e2db2df
fix(deps): update dependency pathspec to v0.12.1 (#613)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-12-12 08:55:06 +01:00
renovate[bot] 787c09a741 chore(deps): update dependency ruff to v0.1.7 2023-12-11 02:16:03 +01:00
renovate[bot] 95c2a6aeaf chore(docker): update python:3.12-alpine docker digest to c793b92 2023-12-09 07:35:33 +01:00
renovate[bot] 855f48894a chore(docker): update python:3.12-alpine docker digest to 401aa10 2023-12-09 04:23:04 +01:00
Robert Kaussow 2270051d0d
ci: exclude dockerhub from linkcheck due to rate limiting 2023-12-07 09:08:22 +01:00
renovate[bot] c0f100b70e
chore(deps): update quay.io/thegeeklab/wp-docker-buildx docker tag to v2 (#610)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-12-07 08:40:11 +01:00
21 changed files with 521 additions and 567 deletions

View File

@ -53,11 +53,7 @@ branches:
strict: false
contexts:
- ci/woodpecker/pr/lint
- ci/woodpecker/pr/test/1
- ci/woodpecker/pr/test/2
- ci/woodpecker/pr/test/3
- ci/woodpecker/pr/test/4
- ci/woodpecker/pr/test/5
- ci/woodpecker/pr/test
- ci/woodpecker/pr/build-package
- ci/woodpecker/pr/build-container
- ci/woodpecker/pr/docs

1
.lycheeignore Normal file
View File

@ -0,0 +1 @@
https://hub.docker.com/r/thegeeklab/*

View File

@ -6,3 +6,5 @@
language: python
pass_filenames: False
always_run: True
additional_dependencies:
- .[ansible-core]

View File

@ -6,15 +6,14 @@ when:
- ${CI_REPO_DEFAULT_BRANCH}
steps:
build:
- name: build
image: docker.io/library/python:3.12
commands:
- git fetch --depth=2147483647
- pip install poetry poetry-dynamic-versioning -qq
- poetry build
dryrun:
image: quay.io/thegeeklab/wp-docker-buildx:1
- name: dryrun
image: quay.io/thegeeklab/wp-docker-buildx:4
settings:
containerfile: Containerfile.multiarch
dry_run: true
@ -26,9 +25,9 @@ steps:
when:
- event: [pull_request]
publish-dockerhub:
- name: publish-dockerhub
image: quay.io/thegeeklab/wp-docker-buildx:4
group: container
image: quay.io/thegeeklab/wp-docker-buildx:1
settings:
auto_tag: true
containerfile: Containerfile.multiarch
@ -47,9 +46,9 @@ steps:
branch:
- ${CI_REPO_DEFAULT_BRANCH}
publish-quay:
- name: publish-quay
image: quay.io/thegeeklab/wp-docker-buildx:4
group: container
image: quay.io/thegeeklab/wp-docker-buildx:1
settings:
auto_tag: true
containerfile: Containerfile.multiarch

View File

@ -6,27 +6,25 @@ when:
- ${CI_REPO_DEFAULT_BRANCH}
steps:
build:
- name: build
image: docker.io/library/python:3.12
commands:
- git fetch --depth=2147483647
- pip install poetry poetry-dynamic-versioning -qq
- poetry build
checksum:
- name: checksum
image: quay.io/thegeeklab/alpine-tools
commands:
- cd dist/ && sha256sum * > ../sha256sum.txt
changelog:
- name: changelog
image: quay.io/thegeeklab/git-sv
commands:
- git fetch --depth=2147483647
- git sv current-version
- git sv release-notes -t ${CI_COMMIT_TAG:-next} -o CHANGELOG.md
- cat CHANGELOG.md
publish-github:
- name: publish-github
image: docker.io/plugins/github-release
settings:
api_key:
@ -40,15 +38,14 @@ steps:
when:
- event: [tag]
publish-pypi:
- name: publish-pypi
image: docker.io/library/python:3.12
secrets:
- source: pypi_password
target: POETRY_HTTP_BASIC_PYPI_PASSWORD
- source: pypi_username
target: POETRY_HTTP_BASIC_PYPI_USERNAME
- source: pypi_password
target: POETRY_HTTP_BASIC_PYPI_PASSWORD
- source: pypi_username
target: POETRY_HTTP_BASIC_PYPI_USERNAME
commands:
- git fetch --depth=2147483647
- pip install poetry poetry-dynamic-versioning -qq
- poetry publish -n
when:

View File

@ -6,51 +6,44 @@ when:
- ${CI_REPO_DEFAULT_BRANCH}
steps:
assets:
- name: assets
image: quay.io/thegeeklab/alpine-tools
commands:
- make doc
markdownlint:
- name: markdownlint
image: quay.io/thegeeklab/markdownlint-cli
group: test
commands:
- markdownlint 'README.md' 'CONTRIBUTING.md'
spellcheck:
- name: spellcheck
image: quay.io/thegeeklab/alpine-tools
group: test
commands:
- spellchecker --files '_docs/**/*.md' 'README.md' 'CONTRIBUTING.md' -d .dictionary -p spell indefinite-article syntax-urls
- spellchecker --files 'docs/**/*.md' 'README.md' 'CONTRIBUTING.md' -d .dictionary -p spell indefinite-article syntax-urls
environment:
FORCE_COLOR: "true"
NPM_CONFIG_LOGLEVEL: "error"
link-validation:
- name: link-validation
image: docker.io/lycheeverse/lychee
group: test
commands:
- lychee --no-progress --format detailed docs/content README.md
testbuild:
image: quay.io/thegeeklab/hugo:0.115.2
commands:
- hugo --panicOnWarning -s docs/ -b http://localhost:8000/
build:
image: quay.io/thegeeklab/hugo:0.115.2
- name: build
image: quay.io/thegeeklab/hugo:0.125.7
commands:
- hugo --panicOnWarning -s docs/
beautify:
- name: beautify
image: quay.io/thegeeklab/alpine-tools
commands:
- html-beautify -r -f 'docs/public/**/*.html'
environment:
FORCE_COLOR: "true"
NPM_CONFIG_LOGLEVEL: error
publish:
- name: publish
image: quay.io/thegeeklab/wp-s3-action
settings:
access_key:
@ -69,15 +62,15 @@ steps:
- event: [push, manual]
branch:
- ${CI_REPO_DEFAULT_BRANCH}
status: [success]
status: [success, failure]
pushrm-dockerhub:
- name: pushrm-dockerhub
image: docker.io/chko/docker-pushrm:1
secrets:
- source: docker_password
target: DOCKER_PASS
target: DOCKER_PASS
- source: docker_username
target: DOCKER_USER
target: DOCKER_USER
environment:
PUSHRM_FILE: README.md
PUSHRM_SHORT: Annotation based documentation for your Ansible roles
@ -88,7 +81,7 @@ steps:
- ${CI_REPO_DEFAULT_BRANCH}
status: [success]
pushrm-quay:
- name: pushrm-quay
image: docker.io/chko/docker-pushrm:1
secrets:
- source: quay_token

View File

@ -6,22 +6,20 @@ when:
- ${CI_REPO_DEFAULT_BRANCH}
steps:
check-format:
- name: check-format
image: docker.io/library/python:3.12
commands:
- git fetch --depth=2147483647
- pip install poetry poetry-dynamic-versioning -qq
- poetry install
- poetry install -E ansible-core
- poetry run ruff format --check --diff ./${CI_REPO_NAME//-/}
environment:
PY_COLORS: "1"
check-coding:
- name: check-coding
image: docker.io/library/python:3.12
commands:
- git fetch --depth=2147483647
- pip install poetry poetry-dynamic-versioning -qq
- poetry install
- poetry run ruff ./${CI_REPO_NAME//-/}
- poetry install -E ansible-core
- poetry run ruff check ./${CI_REPO_NAME//-/}
environment:
PY_COLORS: "1"

View File

@ -8,7 +8,7 @@ when:
runs_on: [success, failure]
steps:
matrix:
- name: matrix
image: quay.io/thegeeklab/wp-matrix
settings:
homeserver:

View File

@ -5,22 +5,30 @@ when:
branch:
- ${CI_REPO_DEFAULT_BRANCH}
matrix:
PYTHON_VERSION:
- "3.8"
- "3.9"
- "3.10"
- "3.11"
- "3.12"
steps:
pytest:
image: docker.io/library/python:${PYTHON_VERSION}
variables:
- &pytest_base
group: pytest
commands:
- git fetch --depth=2147483647
- pip install poetry poetry-dynamic-versioning -qq
- poetry install
- poetry install -E ansible-core
- poetry version
- poetry run ${CI_REPO_NAME} --help
environment:
PY_COLORS: "1"
steps:
- name: python-312
image: docker.io/library/python:3.12
<<: *pytest_base
- name: python-311
image: docker.io/library/python:3.11
<<: *pytest_base
- name: python-310
image: docker.io/library/python:3.10
<<: *pytest_base
- name: python-39
image: docker.io/library/python:3.9
<<: *pytest_base

View File

@ -1,4 +1,4 @@
FROM python:3.12-alpine@sha256:09f18c1f8ca777f63934b415af9a781a0e5aaba5e005ba0475cba71bb3e8e609
FROM python:3.12-alpine@sha256:ef097620baf1272e38264207003b0982285da3236a20ed829bf6bbf1e85fe3cb
LABEL maintainer="Robert Kaussow <mail@thegeeklab.de>"
LABEL org.opencontainers.image.authors="Robert Kaussow <mail@thegeeklab.de>"
@ -14,7 +14,7 @@ ADD dist/ansible_doctor-*.whl /
RUN apk --update add --virtual .build-deps build-base libffi-dev openssl-dev && \
pip install --upgrade --no-cache-dir pip && \
pip install --no-cache-dir $(find / -name "ansible_doctor-*.whl") && \
pip install --no-cache-dir $(find / -name "ansible_doctor-*.whl")[ansible-core] && \
rm -f ansible_doctor-*.whl && \
rm -rf /var/cache/apk/* && \
rm -rf /root/.cache/

View File

@ -1,5 +1,5 @@
# renovate: datasource=github-releases depName=thegeeklab/hugo-geekdoc
THEME_VERSION := v0.44.0
THEME_VERSION := v0.45.0
THEME := hugo-geekdoc
BASEDIR := docs
THEMEDIR := $(BASEDIR)/themes

View File

@ -1,3 +1,10 @@
"""Provide version information."""
__version__ = "0.0.0"
import sys
try:
import ansible # noqa
except ImportError:
sys.exit("ERROR: Python requirements are missing: 'ansible-core' not found.")

View File

@ -312,11 +312,8 @@ class Config:
try:
anyconfig.validate(config, self.schema, ac_schema_safe=False)
except jsonschema.exceptions.ValidationError as e:
schema_error = "Failed validating '{validator}' in schema{schema}\n{message}".format(
validator=e.validator,
schema=format_as_index(list(e.relative_schema_path)[:-1]),
message=e.message,
)
schema = format_as_index(list(e.relative_schema_path)[:-1])
schema_error = f"Failed validating '{e.validator}' in schema {schema}\n{e.message}"
raise ansibledoctor.exception.ConfigError("Configuration error", schema_error) from e
return True
@ -326,7 +323,7 @@ class Config:
tree[key] = (
value
if len(vector) == 1
else self._add_dict_branch(tree[key] if key in tree else {}, vector[1:], value)
else self._add_dict_branch(tree.get(key, {}), vector[1:], value)
)
return tree
@ -334,7 +331,7 @@ class Config:
annotations = {}
if automatic:
for k, item in self.ANNOTATIONS.items():
if "automatic" in item and item["automatic"]:
if item.get("automatic"):
annotations[k] = item
return annotations
@ -342,7 +339,7 @@ class Config:
annotations = []
if automatic:
for k, item in self.ANNOTATIONS.items():
if "automatic" in item and item["automatic"]:
if item.get("automatic"):
annotations.append(k)
return annotations

View File

@ -128,7 +128,7 @@ class LogFilter:
class MultilineFormatter(logging.Formatter):
"""Reset color after newline characters."""
def format(self, record): # noqa
def format(self, record):
record.msg = record.msg.strip().replace("\n", f"\n{colorama.Style.RESET_ALL}... ")
return logging.Formatter.format(self, record)
@ -136,7 +136,7 @@ class MultilineFormatter(logging.Formatter):
class MultilineJsonFormatter(jsonlogger.JsonFormatter):
"""Remove newline characters."""
def format(self, record): # noqa
def format(self, record):
record.msg = record.msg.replace("\n", " ")
return jsonlogger.JsonFormatter.format(self, record)

View File

@ -4,7 +4,6 @@ from collections import defaultdict
from contextlib import suppress
import ruamel.yaml
import yaml
from ansible.parsing.yaml.loader import AnsibleLoader
import ansibledoctor.exception
@ -28,10 +27,10 @@ def parse_yaml_ansible(yamlfile):
loader = AnsibleLoader(yamlfile)
data = loader.get_single_data() or []
except (
yaml.parser.ParserError,
yaml.scanner.ScannerError,
yaml.constructor.ConstructorError,
yaml.composer.ComposerError,
ruamel.yaml.parser.ParserError,
ruamel.yaml.scanner.ScannerError,
ruamel.yaml.constructor.ConstructorError,
ruamel.yaml.composer.ComposerError,
) as e:
message = (
f"{e.context} in line {e.context_mark.line}, column {e.context_mark.line}\n"

View File

@ -4,11 +4,12 @@ title: Using pip
```Shell
# From PyPI as unprivileged user
$ pip install ansible-doctor --user
$ pip install ansible-doctor[ansible-core] --user
# .. or as root
$ sudo pip install ansible-doctor
$ sudo pip install ansible-doctor[ansible-core]
# From Wheel file
$ pip install https://github.com/thegeeklab/ansible-doctor/releases/download/v0.1.1/ansible_doctor-0.1.1-py2.py3-none-any.whl
# Please check first whether a newer version is available.
$ pip install https://github.com/thegeeklab/ansible-doctor/releases/download/v3.1.4/ansible_doctor-3.1.4-py2.py3-none-any.whl[ansible-core]
```

View File

@ -119,8 +119,8 @@ To use _ansible-doctor_ with the [pre-commit](https://pre-commit.com/) framework
{{< highlight yaml "linenos=table" >}}
- repo: https://github.com/thegeeklab/ansible-doctor
# change ref to the latest release from https://github.com/thegeeklab/ansible-doctor/releases
rev: v1.4.8
# update version with `pre-commit autoupdate`
rev: v4.0.4
hooks:
- id: ansible-doctor
{{< /highlight >}}

View File

@ -18,6 +18,5 @@ galaxy_info:
- documentation
dependencies:
- role1
- role: role2
- name: namespace.role3

781
poetry.lock generated

File diff suppressed because it is too large Load Diff

View File

@ -10,7 +10,6 @@ classifiers = [
"Natural Language :: English",
"Operating System :: POSIX",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
@ -22,40 +21,39 @@ classifiers = [
description = "Generate documentation from annotated Ansible roles using templates."
documentation = "https://ansible-doctor.geekdocs.de/"
homepage = "https://ansible-doctor.geekdocs.de/"
include = [
"LICENSE",
]
include = ["LICENSE"]
keywords = ["ansible", "role", "documentation"]
license = "GPL-3.0-only"
name = "ansible-doctor"
packages = [
{include = "ansibledoctor"},
]
packages = [{ include = "ansibledoctor" }]
readme = "README.md"
repository = "https://github.com/thegeeklab/ansible-doctor/"
version = "0.0.0"
[tool.poetry.dependencies]
Jinja2 = "3.1.2"
anyconfig = "0.13.0"
Jinja2 = "3.1.4"
anyconfig = "0.14.0"
appdirs = "1.4.4"
colorama = "0.4.6"
environs = "9.5.0"
jsonschema = "4.20.0"
pathspec = "0.11.2"
python = "^3.8.0"
environs = "11.0.0"
jsonschema = "4.22.0"
pathspec = "0.12.1"
python = "^3.9.0"
python-json-logger = "2.0.7"
"ruamel.yaml" = "0.18.5"
ansible-core = "2.13"
"ruamel.yaml" = "0.18.6"
ansible-core = { version = "2.14.16", optional = true }
[tool.poetry.extras]
ansible-core = ["ansible-core"]
[tool.poetry.scripts]
ansible-doctor = "ansibledoctor.cli:main"
[tool.poetry.group.dev.dependencies]
ruff = "0.1.6"
pytest = "7.4.3"
pytest-mock = "3.12.0"
pytest-cov = "4.1.0"
ruff = "0.4.4"
pytest = "8.2.0"
pytest-mock = "3.14.0"
pytest-cov = "5.0.0"
toml = "0.10.2"
[tool.poetry-dynamic-versioning]
@ -80,21 +78,22 @@ requires = ["poetry-core>=1.0.0", "poetry-dynamic-versioning"]
[tool.ruff]
exclude = [
".git",
"__pycache__",
"build",
"dist",
"test",
"*.pyc",
"*.egg-info",
".cache",
".eggs",
"env*",
".git",
"__pycache__",
"build",
"dist",
"test",
"*.pyc",
"*.egg-info",
".cache",
".eggs",
"env*",
]
line-length = 99
indent-width = 4
[tool.ruff.lint]
# Explanation of errors
#
# D102: Missing docstring in public method
@ -105,36 +104,36 @@ indent-width = 4
# D203: One blank line required before class docstring
# D212: Multi-line docstring summary should start at the first line
ignore = [
"D102",
"D103",
"D105",
"D107",
"D202",
"D203",
"D212",
"UP038",
"RUF012",
"D102",
"D103",
"D105",
"D107",
"D202",
"D203",
"D212",
"UP038",
"RUF012",
]
select = [
"D",
"E",
"F",
"Q",
"W",
"I",
"S",
"BLE",
"N",
"UP",
"B",
"A",
"C4",
"T20",
"SIM",
"RET",
"ARG",
"ERA",
"RUF",
"D",
"E",
"F",
"Q",
"W",
"I",
"S",
"BLE",
"N",
"UP",
"B",
"A",
"C4",
"T20",
"SIM",
"RET",
"ARG",
"ERA",
"RUF",
]
[tool.ruff.format]

View File

@ -1,4 +1,17 @@
{
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
"extends": ["github>thegeeklab/renovate-presets"]
"extends": ["github>thegeeklab/renovate-presets"],
"packageRules": [
{
"description": "Ansible base dependencies",
"matchPackageNames": ["ansible-core"],
"separateMinorPatch": true
},
{
"matchManagers": ["woodpecker"],
"matchFileNames": [".woodpecker/test.yml"],
"matchPackageNames": ["docker.io/library/python"],
"enabled": false
}
]
}