`_
diff --git a/docsrc/changelog.md b/docsrc/changelog.md
deleted file mode 100644
index 66efc0f..0000000
--- a/docsrc/changelog.md
+++ /dev/null
@@ -1,2 +0,0 @@
-```{include} ../CHANGELOG.md
-```
diff --git a/docsrc/cli.rst b/docsrc/cli.rst
deleted file mode 100644
index 2c27a44..0000000
--- a/docsrc/cli.rst
+++ /dev/null
@@ -1,6 +0,0 @@
-Command-line Interface
-======================
-
-.. click:: cookie_composer.cli:cli
- :prog: cookie-composer
- :nested: full
diff --git a/docsrc/conf.py b/docsrc/conf.py
deleted file mode 100644
index b3be850..0000000
--- a/docsrc/conf.py
+++ /dev/null
@@ -1,95 +0,0 @@
-"""
-Sphinx configuration.
-"""
-
-import os
-import sys
-from datetime import date
-
-sys.path.insert(0, os.path.abspath(".."))
-
-import cookie_composer
-
-project = "Cookie Composer"
-author = "Corey Oordt"
-copyright = f"{date.today():%Y}, {author}"
-
-version = cookie_composer.__version__
-release = cookie_composer.__version__
-
-# -- General configuration ---------------------------------------------
-
-extensions = [
- "myst_parser",
- "autodoc2",
- "sphinx.ext.viewcode",
- # "sphinx.ext.autosummary",
- "sphinx.ext.intersphinx",
- "sphinx.ext.autosectionlabel",
- "sphinx.ext.napoleon",
- "sphinx.ext.coverage",
- "sphinx.ext.githubpages",
- "sphinx_click",
-]
-autosectionlabel_prefix_document = True
-autosectionlabel_maxdepth = 2
-autosummary_generate = True
-autodoc2_packages = ["../cookie_composer"]
-napoleon_attr_annotations = True
-napoleon_include_special_with_doc = True
-napoleon_include_private_with_doc = True
-napoleon_include_init_with_doc = True
-myst_enable_extensions = [
- "amsmath",
- "colon_fence",
- "deflist",
- "dollarmath",
- "linkify",
- "replacements",
- "smartquotes",
- "substitution",
- "tasklist",
-]
-intersphinx_mapping = {
- "python": ("https://docs.python.org/3", None),
-}
-
-templates_path = ["_templates"]
-source_suffix = [".rst", ".md"]
-master_doc = "index"
-language = "en"
-exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"]
-pygments_style = "sphinx"
-todo_include_todos = False
-primary_domain = "py"
-
-
-# -- Options for HTML output -------------------------------------------
-
-html_title = "Cookie Composer"
-html_logo = "_static/img/composer-logo.svg"
-html_theme = "sphinx_material"
-html_static_path = ["_static"]
-html_css_files = [
- "css/custom.css",
-]
-html_theme_options = {
- # Set the name of the project to appear in the navigation.
- "nav_title": "Cookie Composer",
- # Specify a base_url used to generate sitemap.xml. If not
- # specified, then no sitemap will be built.
- "base_url": "https://callowayproject.github.io/cookie-composer/",
- # Set the color and the accent color
- "color_primary": "blue",
- "color_accent": "light-blue",
- # Set the repo location to get a badge with stats
- "repo_url": "https://github.com/callowayproject/cookie-composer/",
- "repo_name": "Project",
- # Visible levels of the global TOC; -1 means unlimited
- "globaltoc_depth": 3,
- # If False, expand all TOC entries
- "globaltoc_collapse": False,
- # If True, show hidden TOC entries
- "globaltoc_includehidden": False,
- "master_doc": True,
-}
diff --git a/docsrc/contributing.md b/docsrc/contributing.md
deleted file mode 100644
index 78caf34..0000000
--- a/docsrc/contributing.md
+++ /dev/null
@@ -1,2 +0,0 @@
-```{include} ../CONTRIBUTING.md
-```
diff --git a/docsrc/how-to/index.md b/docsrc/how-to/index.md
deleted file mode 100644
index c064d96..0000000
--- a/docsrc/how-to/index.md
+++ /dev/null
@@ -1,8 +0,0 @@
-# How To...
-
-```{toctree}
----
-maxdepth: 2
----
-access-private-templates
-```
diff --git a/docsrc/index.md b/docsrc/index.md
deleted file mode 100644
index b769f44..0000000
--- a/docsrc/index.md
+++ /dev/null
@@ -1,27 +0,0 @@
-# Cookie composer
-
-```{include} ../README.md
----
-start-after:
----
-```
-
-```{toctree}
----
-hidden:
----
-installation
-tutorial/index
-topic-guides/index
-how-to/index
-cli
-apidocs/index
-contributing
-changelog
-```
-
-## Indices and tables
-
-* {ref}`genindex`
-* {ref}`modindex`
-* {ref}`search`
diff --git a/docsrc/make.bat b/docsrc/make.bat
deleted file mode 100644
index 368fe0f..0000000
--- a/docsrc/make.bat
+++ /dev/null
@@ -1,36 +0,0 @@
-@ECHO OFF
-
-pushd %~dp0
-
-REM Command file for Sphinx documentation
-
-if "%SPHINXBUILD%" == "" (
- set SPHINXBUILD=python -msphinx
-)
-set SOURCEDIR=.
-set BUILDDIR=_build
-set SPHINXPROJ=bin_cookie_composer
-
-if "%1" == "" goto help
-
-%SPHINXBUILD% >NUL 2>NUL
-if errorlevel 9009 (
- echo.
- echo.The Sphinx module was not found. Make sure you have Sphinx installed,
- echo.then set the SPHINXBUILD environment variable to point to the full
- echo.path of the 'sphinx-build' executable. Alternatively you may add the
- echo.Sphinx directory to PATH.
- echo.
- echo.If you don't have Sphinx installed, grab it from
- echo.http://sphinx-doc.org/
- exit /b 1
-)
-
-%SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS%
-goto end
-
-:help
-%SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS%
-
-:end
-popd
diff --git a/docsrc/topic-guides/index.md b/docsrc/topic-guides/index.md
deleted file mode 100644
index c153e26..0000000
--- a/docsrc/topic-guides/index.md
+++ /dev/null
@@ -1,8 +0,0 @@
-# Topic Guides
-
-```{toctree}
----
-maxdepth: 2
----
-composition-files
-```
diff --git a/docsrc/tutorial/index.md b/docsrc/tutorial/index.md
deleted file mode 100644
index 865699f..0000000
--- a/docsrc/tutorial/index.md
+++ /dev/null
@@ -1,10 +0,0 @@
-# Tutorial
-
-```{toctree}
----
-maxdepth: 1
----
-incrementally-layering
-compositions
-composable-templates
-```
diff --git a/mkdocs.yml b/mkdocs.yml
new file mode 100644
index 0000000..c9273fd
--- /dev/null
+++ b/mkdocs.yml
@@ -0,0 +1,119 @@
+site_name: Cookie Composer
+repo_url: https://github.com/callowayproject/cookie-composer
+edit_uri: edit/master/docs/
+copyright: Calloway Project
+watch:
+ - overrides
+theme:
+ name: material
+ custom_dir: overrides
+ logo: assets/img/composer-logo.svg
+ favicon: assets/favicon.png
+ features:
+ - navigation.tabs
+ - navigation.sections
+ - navigation.path
+ - navigation.indexes
+ - toc.integrate
+ - content.action.edit
+ - content.action.view
+ - content.code.annotate
+ - content.tabs.link
+ palette:
+ - media: "(prefers-color-scheme: light)"
+ scheme: default
+ primary: blue grey
+ toggle:
+ icon: material/toggle-switch-off-outline
+ name: Switch to dark mode
+ - media: "(prefers-color-scheme: dark)"
+ scheme: slate
+ toggle:
+ icon: material/toggle-switch
+ name: Switch to light mode
+use_directory_urls: true
+markdown_extensions:
+ - abbr
+ - admonition
+ - attr_list
+ - customblocks
+ - def_list
+ - footnotes
+ - md_in_html
+ - mdx_truly_sane_lists
+ - mkdocs-click
+ - pymdownx.details
+ - pymdownx.emoji:
+ emoji_index: !!python/name:material.extensions.emoji.twemoji
+ emoji_generator: !!python/name:material.extensions.emoji.to_svg
+ - pymdownx.highlight
+ - pymdownx.snippets:
+ base_path: ["docs/_includes"]
+ - pymdownx.superfences:
+ custom_fences:
+ - name: mermaid
+ class: mermaid
+ format: !!python/name:pymdownx.superfences.fence_div_format
+ - pymdownx.tabbed:
+ alternate_style: true
+ slugify: !!python/object/apply:pymdownx.slugs.slugify
+ kwds:
+ case: lower
+ - smarty
+ - toc:
+ permalink: true
+ toc_depth: 3
+ - tables
+
+plugins:
+ - search
+ - git-revision-date-localized
+ - git-authors:
+ show_email_address: false
+ exclude:
+ - reference/api/*
+ - include-markdown
+ - drawio
+ - literate-nav:
+ nav_file: SUMMARY.md
+ - gen-files:
+ scripts:
+ - docs/gen_doc_stubs.py
+ - mkdocstrings:
+ custom_templates: overrides/mkdocstrings
+ handlers:
+ python:
+ import:
+ - https://docs.python.org/3/objects.inv
+ - https://docs.pydantic.dev/latest/objects.inv
+ - https://jinja.palletsprojects.com/en/3.1.x/objects.inv
+ - https://cookiecutter.readthedocs.io/en/stable/objects.inv
+ - https://gitpython.readthedocs.io/en/stable/objects.inv
+ - https://click.palletsprojects.com/en/8.1.x/objects.inv
+ options:
+ allow_inspection: true
+ docstring_style: google
+ docstring_options:
+ ignore_init_summary: true
+ docstring_section_style: spacy
+ enable_inventory: true
+ group_by_category: true
+ members_order: alphabetical
+ merge_init_into_class: true
+ separate_signature: true
+ show_docstring_parameters: true
+ show_root_toc_entry: true
+ show_signature_annotations: true
+ show_source: false
+ show_symbol_type_heading: true
+ show_symbol_type_toc: true
+ show_category_heading: true
+
+extra_javascript:
+ - "https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.0/MathJax.js?config=TeX-MML-AM_CHTML"
+
+extra_css:
+ - assets/css/custom.css
+ - assets/css/mkdocstrings.css
+ - assets/css/cards.css
+ - assets/css/field-list.css
diff --git a/overrides/mkdocstrings/python/material/docstring/attributes.html b/overrides/mkdocstrings/python/material/docstring/attributes.html
new file mode 100644
index 0000000..ce50d65
--- /dev/null
+++ b/overrides/mkdocstrings/python/material/docstring/attributes.html
@@ -0,0 +1,90 @@
+{{ log.debug("Rendering attributes section") }}
+
+{% import "language.html" as lang with context %}
+
+{% if config.docstring_section_style == "table" %}
+ {% block table_style scoped %}
+ {{ section.title or lang.t("Attributes:") }}
+
+
+
+ {{ lang.t("Name") }} |
+ {{ lang.t("Type") }} |
+ {{ lang.t("Description") }} |
+
+
+
+ {% for attribute in section.value %}
+
+ {{ attribute.name }} |
+
+ {% if attribute.annotation %}
+ {% with expression = attribute.annotation %}
+ {% include "expression.html" with context %}
+ {% endwith %}
+ {% endif %}
+ |
+
+
+ {{ attribute.description|convert_markdown(heading_level, html_id) }}
+
+ |
+
+ {% endfor %}
+
+
+ {% endblock table_style %}
+{% elif config.docstring_section_style == "list" %}
+ {% block list_style scoped %}
+ {{ section.title or lang.t("Attributes:") }}
+
+ {% endblock list_style %}
+{% elif config.docstring_section_style == "spacy" %}
+ {% block spacy_style scoped %}
+
+
+
+ {{ (section.title or lang.t("ATTRIBUTE")).rstrip(":").upper() }} |
+ {{ lang.t("DESCRIPTION") }} |
+
+
+
+ {% for attribute in section.value %}
+
+ {{ attribute.name }} |
+
+
+ {{ attribute.description|convert_markdown(heading_level, html_id) }}
+
+
+ {% if attribute.annotation %}
+
+ TYPE:
+ {% with expression = attribute.annotation %}
+ {% include "expression.html" with context %}
+ {% endwith %}
+
+ {% endif %}
+
+ |
+
+ {% endfor %}
+
+
+ {% endblock spacy_style %}
+{% endif %}
diff --git a/overrides/mkdocstrings/python/material/docstring/parameters.html b/overrides/mkdocstrings/python/material/docstring/parameters.html
new file mode 100644
index 0000000..ab4889e
--- /dev/null
+++ b/overrides/mkdocstrings/python/material/docstring/parameters.html
@@ -0,0 +1,98 @@
+{{ log.debug("Rendering parameters section") }}
+
+{% import "language.html" as lang with context %}
+
+{% if config.docstring_section_style == "table" %}
+ {% block table_style scoped %}
+ {{ section.title or lang.t("Parameters:") }}
+
+
+
+ {{ lang.t("Name") }} |
+ {{ lang.t("Type") }} |
+ {{ lang.t("Description") }} |
+ {{ lang.t("Default") }} |
+
+
+
+ {% for parameter in section.value %}
+
+ {{ parameter.name }} |
+
+ {% if parameter.annotation %}
+ {% with expression = parameter.annotation %}
+ {% include "expression.html" with context %}
+ {% endwith %}
+ {% endif %}
+ |
+
+
+ {{ parameter.description|convert_markdown(heading_level, html_id) }}
+
+ |
+
+ {% if parameter.default %}
+ {% with expression = parameter.default %}
+ {% include "expression.html" with context %}
+ {% endwith %}
+ {% else %}
+ {{ lang.t("required") }}
+ {% endif %}
+ |
+
+ {% endfor %}
+
+
+ {% endblock table_style %}
+{% elif config.docstring_section_style == "list" %}
+ {% block list_style scoped %}
+ {{ section.title or lang.t("Parameters:") }}
+
+ {% endblock list_style %}
+{% elif config.docstring_section_style == "spacy" %}
+ {% block spacy_style scoped %}
+ {{ section.title or lang.t("Parameters:") }}
+
+ {% for parameter in section.value %}
+ {{ parameter.name }}
+ -
+
+ {{ parameter.description|convert_markdown(heading_level, html_id) }}
+
+ {% if parameter.annotation %}
+ {{ lang.t("TYPE:") }}
+ {% with expression = parameter.annotation %}
+ {% include "expression.html" with context %}
+ {% endwith %}
+
{% endif %}
+ {% if parameter.default %}
+ {{ lang.t("DEFAULT:") }}
+ {% with expression = parameter.default %}
+ {% include "expression.html" with context %}
+ {% endwith %}
+
{% endif %}
+
+ {% endfor %}
+
+ {% endblock spacy_style %}
+{% endif %}
diff --git a/overrides/mkdocstrings/python/material/docstring/raises.html b/overrides/mkdocstrings/python/material/docstring/raises.html
new file mode 100644
index 0000000..628e41b
--- /dev/null
+++ b/overrides/mkdocstrings/python/material/docstring/raises.html
@@ -0,0 +1,72 @@
+{{ log.debug("Rendering raises section") }}
+
+{% import "language.html" as lang with context %}
+
+{% if config.docstring_section_style == "table" %}
+ {% block table_style scoped %}
+ {{ section.title or lang.t("Raises:") }}
+
+
+
+ {{ lang.t("Type") }} |
+ {{ lang.t("Description") }} |
+
+
+
+ {% for raises in section.value %}
+
+
+ {% if raises.annotation %}
+ {% with expression = raises.annotation %}
+ {% include "expression.html" with context %}
+ {% endwith %}
+ {% endif %}
+ |
+
+
+ {{ raises.description|convert_markdown(heading_level, html_id) }}
+
+ |
+
+ {% endfor %}
+
+
+ {% endblock table_style %}
+{% elif config.docstring_section_style == "list" %}
+ {% block list_style scoped %}
+ {{ lang.t(section.title) or lang.t("Raises:") }}
+
+ {% endblock list_style %}
+{% elif config.docstring_section_style == "spacy" %}
+ {% block spacy_style scoped %}
+ {{ (section.title or lang.t("Raises:")) }}
+
+ {% for raises in section.value %}
+ -
+ {% with expression = raises.annotation %}
+
{% include "expression.html" with context %}
+ {% endwith %}
+
+ -
+
+ {{ raises.description|convert_markdown(heading_level, html_id) }}
+
+
+ {% endfor %}
+
+ {% endblock spacy_style %}
+{% endif %}
diff --git a/overrides/mkdocstrings/python/material/docstring/returns.html b/overrides/mkdocstrings/python/material/docstring/returns.html
new file mode 100644
index 0000000..bd60840
--- /dev/null
+++ b/overrides/mkdocstrings/python/material/docstring/returns.html
@@ -0,0 +1,94 @@
+{{ log.debug("Rendering returns section") }}
+
+{% import "language.html" as lang with context %}
+
+{% if config.docstring_section_style == "table" %}
+ {% block table_style scoped %}
+ {% set name_column = section.value|selectattr("name")|any %}
+ {{ section.title or lang.t("Returns:") }}
+
+
+
+ {% if name_column %}{{ lang.t("Name") }} | {% endif %}
+ {{ lang.t("Type") }} |
+ {{ lang.t("Description") }} |
+
+
+
+ {% for returns in section.value %}
+
+ {% if name_column %}{% if returns.name %}{{ returns.name }} {% endif %} | {% endif %}
+
+ {% if returns.annotation %}
+ {% with expression = returns.annotation %}
+ {% include "expression.html" with context %}
+ {% endwith %}
+ {% endif %}
+ |
+
+
+ {{ returns.description|convert_markdown(heading_level, html_id) }}
+
+ |
+
+ {% endfor %}
+
+
+ {% endblock table_style %}
+{% elif config.docstring_section_style == "list" %}
+ {% block list_style scoped %}
+ {{ section.title or lang.t("Returns:") }}
+
+ {% endblock list_style %}
+{% elif config.docstring_section_style == "spacy" %}
+ {% block spacy_style scoped %}
+ {{ (section.title or lang.t("Returns:")) }}
+
+ {% for returns in section.value %}
+ -
+ {% if returns.name %}
+
{{ returns.name }}
+ {% elif returns.annotation %}
+
+ {% with expression = returns.annotation %}
+ {% include "expression.html" with context %}
+ {% endwith %}
+
+ {% endif %}
+
+ -
+
+ {{ returns.description|convert_markdown(heading_level, html_id) }}
+
+ {% if returns.name and returns.annotation %}
+
+
+ {{ lang.t("TYPE:") }}
+ {% with expression = returns.annotation %}
+ {% include "expression.html" with context %}
+ {% endwith %}
+
+
+ {% endif %}
+
+ {% endfor %}
+
+ {% endblock spacy_style %}
+{% endif %}
diff --git a/overrides/partials/comments.html b/overrides/partials/comments.html
new file mode 100644
index 0000000..b0d1dd3
--- /dev/null
+++ b/overrides/partials/comments.html
@@ -0,0 +1,51 @@
+{% if page.meta.comments %}
+
+
+
+
+
+{% endif %}
diff --git a/pyproject.toml b/pyproject.toml
index 04bda94..4fb502d 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -21,7 +21,7 @@ classifiers = [
]
dependencies = [
"click-log",
- "cookiecutter>=2.4.0",
+ "cookiecutter==2.6.0",
"fsspec[http]",
"ghapi",
"gitpython>=3.1.37",
@@ -50,15 +50,22 @@ dev = [
"pip-tools",
]
docs = [
- "astroid<3.0.0", # astroid 3.0.0 breaks sphinx-autodoc2 0.4.2
- "ghp-import",
- "linkify-it-py",
- "myst-parser",
- "Sphinx>=7.2.0",
- "sphinx-autodoc2",
- "sphinx-click",
- "sphinx-copybutton",
- "sphinx-material",
+ "black",
+ "markdown-customblocks",
+ "mdx-truly-sane-lists",
+ "mkdocs",
+ "mkdocs-click",
+ "mkdocs-drawio",
+ "mkdocs-gen-files",
+ "mkdocs-git-authors-plugin",
+ "mkdocs-git-committers-plugin",
+ "mkdocs-git-revision-date-localized-plugin",
+ "mkdocs-include-markdown-plugin",
+ "mkdocs-literate-nav",
+ "mkdocs-material",
+ "mkdocstrings[python]",
+ "python-frontmatter",
+ "pyyaml",
]
test = [
"coverage>=6.1.2",
diff --git a/requirements.txt b/requirements.txt
deleted file mode 100644
index 5eaadb8..0000000
--- a/requirements.txt
+++ /dev/null
@@ -1 +0,0 @@
--r requirements/prod.txt
diff --git a/requirements/dev.txt b/requirements/dev.txt
deleted file mode 100644
index 4c3b374..0000000
--- a/requirements/dev.txt
+++ /dev/null
@@ -1,317 +0,0 @@
-#
-# This file is autogenerated by pip-compile with Python 3.10
-# by the following command:
-#
-# pip-compile --extra=dev --extra=docs --extra=test --output-file=requirements/dev.txt pyproject.toml
-#
-aiohttp==3.9.4
- # via fsspec
-aiosignal==1.3.1
- # via aiohttp
-alabaster==0.7.13
- # via sphinx
-annotated-types==0.6.0
- # via pydantic
-argopt==0.8.2
- # via git-fame
-arrow==1.3.0
- # via cookiecutter
-astroid==2.15.8
- # via
- # cookie-composer (pyproject.toml)
- # sphinx-autodoc2
-async-timeout==4.0.3
- # via aiohttp
-attrs==23.1.0
- # via aiohttp
-babel==2.13.0
- # via sphinx
-beautifulsoup4==4.12.2
- # via sphinx-material
-binaryornot==0.4.4
- # via cookiecutter
-build==1.0.3
- # via pip-tools
-bump-my-version==0.11.0
- # via cookie-composer (pyproject.toml)
-certifi==2023.7.22
- # via requests
-cfgv==3.4.0
- # via pre-commit
-chardet==5.2.0
- # via binaryornot
-charset-normalizer==3.3.0
- # via
- # aiohttp
- # requests
-click==8.1.7
- # via
- # bump-my-version
- # click-log
- # cookiecutter
- # pip-tools
- # rich-click
- # sphinx-click
- # typer
-click-log==0.4.0
- # via cookie-composer (pyproject.toml)
-cookiecutter==2.4.0
- # via cookie-composer (pyproject.toml)
-coverage[toml]==7.3.2
- # via
- # cookie-composer (pyproject.toml)
- # pytest-cov
-css-html-js-minify==2.5.5
- # via sphinx-material
-distlib==0.3.7
- # via virtualenv
-docutils==0.20.1
- # via
- # myst-parser
- # sphinx
- # sphinx-click
-exceptiongroup==1.1.3
- # via pytest
-fastcore==1.5.29
- # via ghapi
-filelock==3.12.4
- # via virtualenv
-frozenlist==1.4.0
- # via
- # aiohttp
- # aiosignal
-fsspec[http]==2023.9.2
- # via cookie-composer (pyproject.toml)
-generate-changelog==0.9.2
- # via cookie-composer (pyproject.toml)
-ghapi==1.0.4
- # via cookie-composer (pyproject.toml)
-ghp-import==2.1.0
- # via cookie-composer (pyproject.toml)
-git-fame==2.0.1
- # via cookie-composer (pyproject.toml)
-gitdb==4.0.11
- # via gitpython
-gitpython==3.1.41
- # via
- # cookie-composer (pyproject.toml)
- # generate-changelog
-identify==2.5.30
- # via pre-commit
-idna==3.7
- # via
- # requests
- # yarl
-imagesize==1.4.1
- # via sphinx
-immutabledict==3.0.0
- # via cookie-composer (pyproject.toml)
-iniconfig==2.0.0
- # via pytest
-jinja2==3.1.3
- # via
- # cookiecutter
- # generate-changelog
- # myst-parser
- # sphinx
-lazy-object-proxy==1.9.0
- # via astroid
-linkify-it-py==2.0.2
- # via cookie-composer (pyproject.toml)
-lxml==4.9.3
- # via sphinx-material
-markdown-it-py==3.0.0
- # via
- # mdit-py-plugins
- # myst-parser
- # rich
-markupsafe==2.1.3
- # via jinja2
-mdit-py-plugins==0.4.0
- # via myst-parser
-mdurl==0.1.2
- # via markdown-it-py
-more-itertools==10.1.0
- # via generate-changelog
-multidict==6.0.4
- # via
- # aiohttp
- # yarl
-myst-parser==2.0.0
- # via cookie-composer (pyproject.toml)
-nodeenv==1.8.0
- # via pre-commit
-orjson==3.9.15
- # via cookie-composer (pyproject.toml)
-packaging==23.2
- # via
- # build
- # fastcore
- # ghapi
- # pytest
- # sphinx
-pip-tools==7.3.0
- # via cookie-composer (pyproject.toml)
-platformdirs==3.11.0
- # via virtualenv
-pluggy==1.3.0
- # via pytest
-pre-commit==3.5.0
- # via cookie-composer (pyproject.toml)
-prompt-toolkit==3.0.36
- # via questionary
-pydantic==2.4.2
- # via
- # bump-my-version
- # cookie-composer (pyproject.toml)
- # pydantic-settings
-pydantic-core==2.10.1
- # via pydantic
-pydantic-settings==2.0.3
- # via bump-my-version
-pygments==2.16.1
- # via
- # rich
- # sphinx
-pyproject-hooks==1.0.0
- # via build
-pytest==7.4.2
- # via
- # cookie-composer (pyproject.toml)
- # pytest-cov
- # pytest-env
- # pytest-mock
-pytest-cov==4.1.0
- # via cookie-composer (pyproject.toml)
-pytest-env==1.0.1
- # via cookie-composer (pyproject.toml)
-pytest-mock==3.12.0
- # via cookie-composer (pyproject.toml)
-python-dateutil==2.8.2
- # via
- # arrow
- # ghp-import
-python-dotenv==1.0.0
- # via pydantic-settings
-python-slugify[unidecode]==8.0.1
- # via
- # cookiecutter
- # sphinx-material
-pyyaml==6.0.1
- # via
- # cookiecutter
- # myst-parser
- # pre-commit
-questionary==2.0.1
- # via cookie-composer (pyproject.toml)
-requests==2.31.0
- # via
- # cookie-composer (pyproject.toml)
- # cookiecutter
- # fsspec
- # sphinx
-rich==13.6.0
- # via
- # bump-my-version
- # cookiecutter
- # rich-click
-rich-click==1.7.0
- # via
- # bump-my-version
- # cookie-composer (pyproject.toml)
-ruamel-yaml==0.17.40
- # via
- # cookie-composer (pyproject.toml)
- # generate-changelog
-ruamel-yaml-clib==0.2.8
- # via ruamel-yaml
-six==1.16.0
- # via python-dateutil
-smmap==5.0.1
- # via gitdb
-snowballstemmer==2.2.0
- # via sphinx
-soupsieve==2.5
- # via beautifulsoup4
-sphinx==7.2.6
- # via
- # cookie-composer (pyproject.toml)
- # myst-parser
- # sphinx-click
- # sphinx-copybutton
- # sphinx-material
- # sphinxcontrib-applehelp
- # sphinxcontrib-devhelp
- # sphinxcontrib-htmlhelp
- # sphinxcontrib-qthelp
- # sphinxcontrib-serializinghtml
-sphinx-autodoc2==0.4.2
- # via cookie-composer (pyproject.toml)
-sphinx-click==5.0.1
- # via cookie-composer (pyproject.toml)
-sphinx-copybutton==0.5.2
- # via cookie-composer (pyproject.toml)
-sphinx-material==0.0.36
- # via cookie-composer (pyproject.toml)
-sphinxcontrib-applehelp==1.0.7
- # via sphinx
-sphinxcontrib-devhelp==1.0.5
- # via sphinx
-sphinxcontrib-htmlhelp==2.0.4
- # via sphinx
-sphinxcontrib-jsmath==1.0.1
- # via sphinx
-sphinxcontrib-qthelp==1.0.6
- # via sphinx
-sphinxcontrib-serializinghtml==1.1.9
- # via sphinx
-tabulate==0.9.0
- # via git-fame
-text-unidecode==1.3
- # via python-slugify
-toml==0.10.2
- # via cookie-composer (pyproject.toml)
-tomli==2.0.1
- # via
- # build
- # coverage
- # pip-tools
- # pyproject-hooks
- # pytest
- # sphinx-autodoc2
-tomlkit==0.12.1
- # via bump-my-version
-tqdm==4.66.3
- # via git-fame
-typer==0.9.0
- # via generate-changelog
-types-python-dateutil==2.8.19.14
- # via arrow
-typing-extensions==4.8.0
- # via
- # astroid
- # pydantic
- # pydantic-core
- # rich-click
- # sphinx-autodoc2
- # typer
-uc-micro-py==1.0.2
- # via linkify-it-py
-unidecode==1.3.7
- # via python-slugify
-urllib3==2.0.7
- # via requests
-virtualenv==20.24.5
- # via pre-commit
-wcwidth==0.2.8
- # via prompt-toolkit
-wheel==0.41.2
- # via pip-tools
-wrapt==1.15.0
- # via astroid
-yarl==1.9.2
- # via aiohttp
-
-# The following packages are considered to be unsafe in a requirements file:
-# pip
-# setuptools
diff --git a/requirements/docs.txt b/requirements/docs.txt
deleted file mode 100644
index 7b2e1d5..0000000
--- a/requirements/docs.txt
+++ /dev/null
@@ -1,224 +0,0 @@
-#
-# This file is autogenerated by pip-compile with Python 3.10
-# by the following command:
-#
-# pip-compile --extra=docs --output-file=requirements/docs.txt pyproject.toml
-#
-aiohttp==3.9.4
- # via fsspec
-aiosignal==1.3.1
- # via aiohttp
-alabaster==0.7.13
- # via sphinx
-annotated-types==0.6.0
- # via pydantic
-arrow==1.3.0
- # via cookiecutter
-astroid==2.15.8
- # via
- # cookie-composer (pyproject.toml)
- # sphinx-autodoc2
-async-timeout==4.0.3
- # via aiohttp
-attrs==23.1.0
- # via aiohttp
-babel==2.13.0
- # via sphinx
-beautifulsoup4==4.12.2
- # via sphinx-material
-binaryornot==0.4.4
- # via cookiecutter
-certifi==2023.7.22
- # via requests
-chardet==5.2.0
- # via binaryornot
-charset-normalizer==3.3.0
- # via
- # aiohttp
- # requests
-click==8.1.7
- # via
- # click-log
- # cookiecutter
- # rich-click
- # sphinx-click
-click-log==0.4.0
- # via cookie-composer (pyproject.toml)
-cookiecutter==2.4.0
- # via cookie-composer (pyproject.toml)
-css-html-js-minify==2.5.5
- # via sphinx-material
-docutils==0.20.1
- # via
- # myst-parser
- # sphinx
- # sphinx-click
-fastcore==1.5.29
- # via ghapi
-frozenlist==1.4.0
- # via
- # aiohttp
- # aiosignal
-fsspec[http]==2023.9.2
- # via cookie-composer (pyproject.toml)
-ghapi==1.0.4
- # via cookie-composer (pyproject.toml)
-ghp-import==2.1.0
- # via cookie-composer (pyproject.toml)
-gitdb==4.0.11
- # via gitpython
-gitpython==3.1.41
- # via cookie-composer (pyproject.toml)
-idna==3.7
- # via
- # requests
- # yarl
-imagesize==1.4.1
- # via sphinx
-immutabledict==3.0.0
- # via cookie-composer (pyproject.toml)
-jinja2==3.1.3
- # via
- # cookiecutter
- # myst-parser
- # sphinx
-lazy-object-proxy==1.9.0
- # via astroid
-linkify-it-py==2.0.2
- # via cookie-composer (pyproject.toml)
-lxml==4.9.3
- # via sphinx-material
-markdown-it-py==3.0.0
- # via
- # mdit-py-plugins
- # myst-parser
- # rich
-markupsafe==2.1.3
- # via jinja2
-mdit-py-plugins==0.4.0
- # via myst-parser
-mdurl==0.1.2
- # via markdown-it-py
-multidict==6.0.4
- # via
- # aiohttp
- # yarl
-myst-parser==2.0.0
- # via cookie-composer (pyproject.toml)
-orjson==3.9.15
- # via cookie-composer (pyproject.toml)
-packaging==23.2
- # via
- # fastcore
- # ghapi
- # sphinx
-prompt-toolkit==3.0.36
- # via questionary
-pydantic==2.4.2
- # via cookie-composer (pyproject.toml)
-pydantic-core==2.10.1
- # via pydantic
-pygments==2.16.1
- # via
- # rich
- # sphinx
-python-dateutil==2.8.2
- # via
- # arrow
- # ghp-import
-python-slugify[unidecode]==8.0.1
- # via
- # cookiecutter
- # sphinx-material
-pyyaml==6.0.1
- # via
- # cookiecutter
- # myst-parser
-questionary==2.0.1
- # via cookie-composer (pyproject.toml)
-requests==2.31.0
- # via
- # cookie-composer (pyproject.toml)
- # cookiecutter
- # fsspec
- # sphinx
-rich==13.6.0
- # via
- # cookiecutter
- # rich-click
-rich-click==1.7.0
- # via cookie-composer (pyproject.toml)
-ruamel-yaml==0.17.40
- # via cookie-composer (pyproject.toml)
-ruamel-yaml-clib==0.2.8
- # via ruamel-yaml
-six==1.16.0
- # via python-dateutil
-smmap==5.0.1
- # via gitdb
-snowballstemmer==2.2.0
- # via sphinx
-soupsieve==2.5
- # via beautifulsoup4
-sphinx==7.2.6
- # via
- # cookie-composer (pyproject.toml)
- # myst-parser
- # sphinx-click
- # sphinx-copybutton
- # sphinx-material
- # sphinxcontrib-applehelp
- # sphinxcontrib-devhelp
- # sphinxcontrib-htmlhelp
- # sphinxcontrib-qthelp
- # sphinxcontrib-serializinghtml
-sphinx-autodoc2==0.4.2
- # via cookie-composer (pyproject.toml)
-sphinx-click==5.0.1
- # via cookie-composer (pyproject.toml)
-sphinx-copybutton==0.5.2
- # via cookie-composer (pyproject.toml)
-sphinx-material==0.0.36
- # via cookie-composer (pyproject.toml)
-sphinxcontrib-applehelp==1.0.7
- # via sphinx
-sphinxcontrib-devhelp==1.0.5
- # via sphinx
-sphinxcontrib-htmlhelp==2.0.4
- # via sphinx
-sphinxcontrib-jsmath==1.0.1
- # via sphinx
-sphinxcontrib-qthelp==1.0.6
- # via sphinx
-sphinxcontrib-serializinghtml==1.1.9
- # via sphinx
-text-unidecode==1.3
- # via python-slugify
-toml==0.10.2
- # via cookie-composer (pyproject.toml)
-tomli==2.0.1
- # via sphinx-autodoc2
-types-python-dateutil==2.8.19.14
- # via arrow
-typing-extensions==4.8.0
- # via
- # astroid
- # pydantic
- # pydantic-core
- # rich-click
- # sphinx-autodoc2
-uc-micro-py==1.0.2
- # via linkify-it-py
-unidecode==1.3.7
- # via python-slugify
-urllib3==2.0.7
- # via requests
-wcwidth==0.2.8
- # via prompt-toolkit
-wrapt==1.15.0
- # via astroid
-yarl==1.9.2
- # via aiohttp
-
-# The following packages are considered to be unsafe in a requirements file:
-# pip
diff --git a/requirements/prod.txt b/requirements/prod.txt
deleted file mode 100644
index f3197b0..0000000
--- a/requirements/prod.txt
+++ /dev/null
@@ -1,130 +0,0 @@
-#
-# This file is autogenerated by pip-compile with Python 3.10
-# by the following command:
-#
-# pip-compile --output-file=requirements/prod.txt pyproject.toml
-#
-aiohttp==3.9.4
- # via fsspec
-aiosignal==1.3.1
- # via aiohttp
-annotated-types==0.6.0
- # via pydantic
-arrow==1.3.0
- # via cookiecutter
-async-timeout==4.0.3
- # via aiohttp
-attrs==23.1.0
- # via aiohttp
-binaryornot==0.4.4
- # via cookiecutter
-certifi==2023.7.22
- # via requests
-chardet==5.2.0
- # via binaryornot
-charset-normalizer==3.3.0
- # via
- # aiohttp
- # requests
-click==8.1.7
- # via
- # click-log
- # cookiecutter
- # rich-click
-click-log==0.4.0
- # via cookie-composer (pyproject.toml)
-cookiecutter==2.4.0
- # via cookie-composer (pyproject.toml)
-fastcore==1.5.29
- # via ghapi
-frozenlist==1.4.0
- # via
- # aiohttp
- # aiosignal
-fsspec[http]==2023.9.2
- # via cookie-composer (pyproject.toml)
-ghapi==1.0.4
- # via cookie-composer (pyproject.toml)
-gitdb==4.0.11
- # via gitpython
-gitpython==3.1.41
- # via cookie-composer (pyproject.toml)
-idna==3.7
- # via
- # requests
- # yarl
-immutabledict==3.0.0
- # via cookie-composer (pyproject.toml)
-jinja2==3.1.3
- # via cookiecutter
-markdown-it-py==3.0.0
- # via rich
-markupsafe==2.1.3
- # via jinja2
-mdurl==0.1.2
- # via markdown-it-py
-multidict==6.0.4
- # via
- # aiohttp
- # yarl
-orjson==3.9.15
- # via cookie-composer (pyproject.toml)
-packaging==23.2
- # via
- # fastcore
- # ghapi
-prompt-toolkit==3.0.36
- # via questionary
-pydantic==2.4.2
- # via cookie-composer (pyproject.toml)
-pydantic-core==2.10.1
- # via pydantic
-pygments==2.16.1
- # via rich
-python-dateutil==2.8.2
- # via arrow
-python-slugify==8.0.1
- # via cookiecutter
-pyyaml==6.0.1
- # via cookiecutter
-questionary==2.0.1
- # via cookie-composer (pyproject.toml)
-requests==2.31.0
- # via
- # cookie-composer (pyproject.toml)
- # cookiecutter
- # fsspec
-rich==13.6.0
- # via
- # cookiecutter
- # rich-click
-rich-click==1.7.0
- # via cookie-composer (pyproject.toml)
-ruamel-yaml==0.17.40
- # via cookie-composer (pyproject.toml)
-ruamel-yaml-clib==0.2.8
- # via ruamel-yaml
-six==1.16.0
- # via python-dateutil
-smmap==5.0.1
- # via gitdb
-text-unidecode==1.3
- # via python-slugify
-toml==0.10.2
- # via cookie-composer (pyproject.toml)
-types-python-dateutil==2.8.19.14
- # via arrow
-typing-extensions==4.8.0
- # via
- # pydantic
- # pydantic-core
- # rich-click
-urllib3==2.0.7
- # via requests
-wcwidth==0.2.8
- # via prompt-toolkit
-yarl==1.9.2
- # via aiohttp
-
-# The following packages are considered to be unsafe in a requirements file:
-# pip
diff --git a/requirements/test.txt b/requirements/test.txt
deleted file mode 100644
index a3e0781..0000000
--- a/requirements/test.txt
+++ /dev/null
@@ -1,176 +0,0 @@
-#
-# This file is autogenerated by pip-compile with Python 3.10
-# by the following command:
-#
-# pip-compile --extra=test --output-file=requirements/test.txt pyproject.toml
-#
-aiohttp==3.9.4
- # via fsspec
-aiosignal==1.3.1
- # via aiohttp
-annotated-types==0.6.0
- # via pydantic
-arrow==1.3.0
- # via cookiecutter
-async-timeout==4.0.3
- # via aiohttp
-attrs==23.1.0
- # via aiohttp
-binaryornot==0.4.4
- # via cookiecutter
-certifi==2023.7.22
- # via requests
-cfgv==3.4.0
- # via pre-commit
-chardet==5.2.0
- # via binaryornot
-charset-normalizer==3.3.0
- # via
- # aiohttp
- # requests
-click==8.1.7
- # via
- # click-log
- # cookiecutter
- # rich-click
-click-log==0.4.0
- # via cookie-composer (pyproject.toml)
-cookiecutter==2.4.0
- # via cookie-composer (pyproject.toml)
-coverage[toml]==7.3.2
- # via
- # cookie-composer (pyproject.toml)
- # pytest-cov
-distlib==0.3.7
- # via virtualenv
-exceptiongroup==1.1.3
- # via pytest
-fastcore==1.5.29
- # via ghapi
-filelock==3.12.4
- # via virtualenv
-frozenlist==1.4.0
- # via
- # aiohttp
- # aiosignal
-fsspec[http]==2023.9.2
- # via cookie-composer (pyproject.toml)
-ghapi==1.0.4
- # via cookie-composer (pyproject.toml)
-gitdb==4.0.11
- # via gitpython
-gitpython==3.1.41
- # via cookie-composer (pyproject.toml)
-identify==2.5.30
- # via pre-commit
-idna==3.7
- # via
- # requests
- # yarl
-immutabledict==3.0.0
- # via cookie-composer (pyproject.toml)
-iniconfig==2.0.0
- # via pytest
-jinja2==3.1.3
- # via cookiecutter
-markdown-it-py==3.0.0
- # via rich
-markupsafe==2.1.3
- # via jinja2
-mdurl==0.1.2
- # via markdown-it-py
-multidict==6.0.4
- # via
- # aiohttp
- # yarl
-nodeenv==1.8.0
- # via pre-commit
-orjson==3.9.15
- # via cookie-composer (pyproject.toml)
-packaging==23.2
- # via
- # fastcore
- # ghapi
- # pytest
-platformdirs==3.11.0
- # via virtualenv
-pluggy==1.3.0
- # via pytest
-pre-commit==3.5.0
- # via cookie-composer (pyproject.toml)
-prompt-toolkit==3.0.36
- # via questionary
-pydantic==2.4.2
- # via cookie-composer (pyproject.toml)
-pydantic-core==2.10.1
- # via pydantic
-pygments==2.16.1
- # via rich
-pytest==7.4.2
- # via
- # cookie-composer (pyproject.toml)
- # pytest-cov
- # pytest-env
- # pytest-mock
-pytest-cov==4.1.0
- # via cookie-composer (pyproject.toml)
-pytest-env==1.0.1
- # via cookie-composer (pyproject.toml)
-pytest-mock==3.12.0
- # via cookie-composer (pyproject.toml)
-python-dateutil==2.8.2
- # via arrow
-python-slugify==8.0.1
- # via cookiecutter
-pyyaml==6.0.1
- # via
- # cookiecutter
- # pre-commit
-questionary==2.0.1
- # via cookie-composer (pyproject.toml)
-requests==2.31.0
- # via
- # cookie-composer (pyproject.toml)
- # cookiecutter
- # fsspec
-rich==13.6.0
- # via
- # cookiecutter
- # rich-click
-rich-click==1.7.0
- # via cookie-composer (pyproject.toml)
-ruamel-yaml==0.17.40
- # via cookie-composer (pyproject.toml)
-ruamel-yaml-clib==0.2.8
- # via ruamel-yaml
-six==1.16.0
- # via python-dateutil
-smmap==5.0.1
- # via gitdb
-text-unidecode==1.3
- # via python-slugify
-toml==0.10.2
- # via cookie-composer (pyproject.toml)
-tomli==2.0.1
- # via
- # coverage
- # pytest
-types-python-dateutil==2.8.19.14
- # via arrow
-typing-extensions==4.8.0
- # via
- # pydantic
- # pydantic-core
- # rich-click
-urllib3==2.0.7
- # via requests
-virtualenv==20.24.5
- # via pre-commit
-wcwidth==0.2.8
- # via prompt-toolkit
-yarl==1.9.2
- # via aiohttp
-
-# The following packages are considered to be unsafe in a requirements file:
-# pip
-# setuptools
diff --git a/tests/conftest.py b/tests/conftest.py
index 551fcb6..dd232a0 100644
--- a/tests/conftest.py
+++ b/tests/conftest.py
@@ -1,11 +1,16 @@
"""Testing configuration."""
import shutil
+import sys
from pathlib import Path
import pytest
from git import Actor, Repo
+from cookie_composer.utils import remove_single_path
+
+skip_if_windows = pytest.mark.skipif(sys.platform == "win32", reason="does not run on windows yet")
+
@pytest.fixture(autouse=True)
def isolated_filesystem(monkeypatch, tmp_path):
@@ -62,7 +67,7 @@ def default_origin(tmp_path: Path) -> Repo:
tmp_repo.remotes.origin.push("remote-branch")
tmp_repo.remotes.origin.push("v1.0.0")
- shutil.rmtree(tmp_repo_path)
+ remove_single_path(tmp_repo_path)
return origin
diff --git a/tests/fixtures/local_extension_template/local_extensions/main.py b/tests/fixtures/local_extension_template/local_extensions/main.py
index 0088832..5029245 100644
--- a/tests/fixtures/local_extension_template/local_extensions/main.py
+++ b/tests/fixtures/local_extension_template/local_extensions/main.py
@@ -1,4 +1,4 @@
-"""Provides a custom extension, exposing a ``foobar`` filter."""
+"""Provides a custom extension, exposing a `foobar` filter."""
from cookiecutter.utils import simple_filter
from jinja2.ext import Extension
diff --git a/tests/test_authentication.py b/tests/test_authentication.py
index 2e15e7d..c07f58e 100644
--- a/tests/test_authentication.py
+++ b/tests/test_authentication.py
@@ -5,6 +5,7 @@
from typing import Optional
from cookie_composer import authentication
+from tests.conftest import skip_if_windows
class MockPath:
@@ -59,6 +60,7 @@ def create_mock_path(contents: str = "") -> MockPath:
return MockPath(contents=contents)
+@skip_if_windows
def test_get_hosts_file(mocker):
"""Getting the host file should return the correct path."""
mocker.patch(
@@ -71,6 +73,7 @@ def test_get_hosts_file(mocker):
assert path.read_text() == "{}"
+@skip_if_windows
def test_login_to_svc_with_no_hosts_file(mocker):
"""Login to the service with no hosts file."""
mocked_path = create_mock_path("")
@@ -94,6 +97,7 @@ def test_login_to_svc_with_no_hosts_file(mocker):
}
+@skip_if_windows
def test_get_cached_token(mocker):
"""When the cached token exists, it gets returned."""
mocked_path = create_mock_path(
@@ -104,6 +108,7 @@ def test_get_cached_token(mocker):
assert authentication.get_cached_token("idon'texist") is None
+@skip_if_windows
def test_add_auth_to_url(mocker):
"""A host with a cached token returns a new URL."""
mocked_path = create_mock_path(
diff --git a/tests/test_commands/test_update.py b/tests/test_commands/test_update.py
index b3b5fb9..565f6fb 100644
--- a/tests/test_commands/test_update.py
+++ b/tests/test_commands/test_update.py
@@ -11,6 +11,7 @@
from cookie_composer.commands import update
from cookie_composer.git_commands import checkout_branch, get_repo
from cookie_composer.templates.types import TemplateFormat, Locality
+from cookie_composer.utils import remove_single_path
@pytest.fixture(scope="module")
@@ -36,7 +37,7 @@ def git_template(fixtures_path: Path, tmp_path_factory) -> dict:
origin = Repo.init(origin_path, bare=True)
tmp_repo.create_remote("origin", str(origin_path))
tmp_repo.remotes.origin.push("master")
- shutil.rmtree(tmp_repo_path)
+ remove_single_path(tmp_repo_path)
template_updated_sha = origin.heads.master.commit.hexsha
template_initial_sha = origin.heads.master.commit.parents[0].hexsha