Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: auto docs using mkdocstrings #234

Merged
merged 1 commit into from
Mar 6, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ jobs:
#----------------------------------------------
- name: Install dependencies
# if: steps.cached-poetry-dependencies.outputs.cache-hit != 'true'
run: poetry install --no-interaction --no-root
run: poetry install --no-interaction --no-root --no-ansi --only tests
#----------------------------------------------
# run test suite
#----------------------------------------------
Expand Down
27 changes: 27 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
repos:
- repo: https:/pre-commit/pre-commit-hooks
rev: v4.4.0
hooks:
- id: check-added-large-files
- id: check-ast
- id: check-case-conflict
- id: check-toml
- id: check-yaml
- id: end-of-file-fixer
- id: debug-statements
- id: destroyed-symlinks
- id: trailing-whitespace
# will be uncommented when all the
# scripts have been revised once
# - repo: https:/psf/black
# rev: 23.1.0
# hooks:
# - id: black
# - repo: https:/PyCQA/isort
# rev: 5.12.0
# hooks:
# - id: isort
# - repo: https:/PyCQA/flake8
# rev: 6.0.0
# hooks:
# - id: flake8
15 changes: 15 additions & 0 deletions docs/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Reference

::: validators.utils

::: validators.between

::: validators.btc_address

::: validators.card

::: validators.domain

::: validators.email

::: validators.length
27 changes: 27 additions & 0 deletions mkdocs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
site_name: "validators"
site_description: "Automatic documentation from sources, for MkDocs."
site_url: "https://python-validators.github.io/"
repo_url: "https:/python-validators/validators"
edit_uri: "tree/master/docs/"
repo_name: "validators/validators"
site_dir: "site"
watch: [README.md, validators/]

nav:
- Reference: index.md

theme:
name: material

plugins:
- search
- mkdocstrings:
handlers:
python:
import:
- https://docs.python-requests.org/en/master/objects.inv

extra:
social:
- icon: fontawesome/brands/github
link: https:/python-validators/validators
Loading