diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index 7a3ff7d6..e119a4c1 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -15,9 +15,9 @@ jobs: with: python-version: '3.11' - name: Install dependencies - run: pip install --no-deps -r requirements/requirements-docs.txt + run: pip install hatch - name: Build site - run: mkdocs build --strict + run: hatch run docs:build deploy: runs-on: ubuntu-latest @@ -33,6 +33,6 @@ jobs: with: python-version: '3.11' - name: Install dependencies - run: pip install --no-deps -r requirements/requirements-docs.txt + run: pip install hatch - name: Deploy to GitHub Pages - run: mkdocs gh-deploy --force + run: hatch run docs:deploy diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index c9fe5811..d0d5f846 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -121,11 +121,11 @@ hatch run lint:check If you add a new plugin to mkdocs.yml, you don't need to add it to any "requirements" file, because that is managed automatically. -> INFO: If you don't want to use Hatch, for documentation you can install requirements into a virtualenv, in one of these ways (with `.venv` being the virtualenv directory): +> INFO: If you don't want to use Hatch, for documentation you can install dependencies into a virtualenv (with `.venv` being the virtualenv directory): > > ```bash -> .venv/bin/pip install -r requirements/requirements-docs.txt # Exact versions of dependencies. -> .venv/bin/pip install -r $(mkdocs get-deps) # Latest versions of all dependencies. +> .venv/bin/pip install --editable . +> .venv/bin/pip install $(mkdocs get-deps) # Additional dependencies from mkdocs.yml plugins/themes. > ``` ## Translating themes diff --git a/pyproject.toml b/pyproject.toml index c6a4b99d..7bce6463 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -106,7 +106,7 @@ dependencies = [ ] [tool.hatch.env] -requires = ["hatch-mkdocs", "hatch-pip-compile"] +requires = ["hatch-mkdocs"] [tool.hatch.envs.default.scripts] all = [ @@ -169,7 +169,6 @@ dependencies = [ check = "mypy mkdocs" [tool.hatch.envs.style] -type = "pip-compile" detached = true dependencies = [ "black", @@ -208,7 +207,6 @@ check = ["markdown", "js", "css", "spelling"] [tool.hatch.env.collectors.mkdocs.docs] path = "mkdocs.yml" [tool.hatch.envs.docs] -type = "pip-compile" detached = false [tool.black] diff --git a/requirements/requirements-docs.txt b/requirements/requirements-docs.txt deleted file mode 100644 index 670f9bf0..00000000 --- a/requirements/requirements-docs.txt +++ /dev/null @@ -1,134 +0,0 @@ -# -# This file is autogenerated by hatch-pip-compile with Python 3.11 -# -# - markdown-callouts -# - mdx-gh-links -# - mkdocs -# - mkdocs-autorefs -# - mkdocs-click -# - mkdocs-literate-nav -# - mkdocs-redirects -# - mkdocstrings -# - mkdocstrings-python -# - pymdown-extensions -# - click>=7.0 -# - colorama>=0.4; platform_system == "Windows" -# - ghp-import>=1.0 -# - importlib-metadata>=4.4; python_version < "3.10" -# - jinja2>=2.11.1 -# - markdown>=3.3.6 -# - markupsafe>=2.0.1 -# - mergedeep>=1.3.4 -# - mkdocs-get-deps>=0.2.0 -# - packaging>=20.5 -# - pathspec>=0.11.1 -# - pyyaml-env-tag>=0.1 -# - pyyaml>=5.1 -# - watchdog>=2.0 -# - -click==8.1.8 - # via - # hatch.envs.docs - # mkdocs - # mkdocs-click - # mkdocstrings -colorama==0.4.6 - # via griffe -ghp-import==2.1.0 - # via - # hatch.envs.docs - # mkdocs -griffe==1.14.0 - # via mkdocstrings-python -jinja2==3.1.6 - # via - # hatch.envs.docs - # mkdocs - # mkdocstrings -markdown==3.9 - # via - # hatch.envs.docs - # markdown-callouts - # mdx-gh-links - # mkdocs - # mkdocs-autorefs - # mkdocs-click - # mkdocstrings - # pymdown-extensions -markdown-callouts==0.4.0 - # via hatch.envs.docs -markupsafe==3.0.3 - # via - # hatch.envs.docs - # jinja2 - # mkdocs - # mkdocstrings -mdx-gh-links==0.4 - # via hatch.envs.docs -mergedeep==1.3.4 - # via - # hatch.envs.docs - # mkdocs - # mkdocs-get-deps -mkdocs==1.6.1 - # via - # hatch.envs.docs - # mkdocs-autorefs - # mkdocs-literate-nav - # mkdocs-redirects - # mkdocstrings -mkdocs-autorefs==1.4.4 - # via - # hatch.envs.docs - # mkdocstrings -mkdocs-click==0.9.0 - # via hatch.envs.docs -mkdocs-get-deps==0.2.2 - # via hatch.envs.docs -mkdocs-literate-nav==0.6.3 - # via hatch.envs.docs -mkdocs-redirects==1.2.2 - # via hatch.envs.docs -mkdocstrings==0.30.1 - # via - # hatch.envs.docs - # mkdocstrings-python -mkdocstrings-python==1.18.2 - # via hatch.envs.docs -packaging==26.1 - # via - # hatch.envs.docs - # mkdocs -pathspec==1.0.4 - # via - # hatch.envs.docs - # mkdocs -platformdirs==4.4.0 - # via - # mkdocs - # mkdocs-get-deps - # mkdocstrings -pymdown-extensions==10.21.2 - # via - # hatch.envs.docs - # mkdocstrings -python-dateutil==2.9.0.post0 - # via ghp-import -pyyaml==6.0.3 - # via - # hatch.envs.docs - # mkdocs - # mkdocs-get-deps - # pymdown-extensions - # pyyaml-env-tag -pyyaml-env-tag==1.1 - # via - # hatch.envs.docs - # mkdocs -six==1.17.0 - # via python-dateutil -watchdog==6.0.0 - # via - # hatch.envs.docs - # mkdocs diff --git a/requirements/requirements-style.txt b/requirements/requirements-style.txt deleted file mode 100644 index a022836f..00000000 --- a/requirements/requirements-style.txt +++ /dev/null @@ -1,24 +0,0 @@ -# -# This file is autogenerated by hatch-pip-compile with Python 3.11 -# -# - black -# - isort -# - ruff -# - -black==25.11.0 - # via hatch.envs.style -click==8.1.8 - # via black -isort==6.1.0 - # via hatch.envs.style -mypy-extensions==1.1.0 - # via black -packaging==26.1 - # via black -pathspec==1.0.4 - # via black -platformdirs==4.4.0 - # via black -ruff==0.15.11 - # via hatch.envs.style