docstring-generator 0.3.4__tar.gz → 1.0.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,108 @@
1
+ Metadata-Version: 2.4
2
+ Name: docstring-generator
3
+ Version: 1.0.2
4
+ Summary: Auto generate docstring from type-hints.
5
+ Author: FelixTheC
6
+ Project-URL: Repository, https://github.com/FelixTheC/docstring_generator
7
+ Classifier: Environment :: Console
8
+ Classifier: Programming Language :: Python :: 3
9
+ Classifier: Topic :: Utilities
10
+ Classifier: Topic :: Software Development :: Documentation
11
+ Classifier: Typing :: Typed
12
+ Requires-Python: >=3.13
13
+ Description-Content-Type: text/markdown
14
+ Requires-Dist: click>=8.1.3
15
+ Requires-Dist: docstring-generator-ext>=1.0.2
16
+
17
+ [![Python 3.10](https://img.shields.io/badge/python-3-blue.svg)](https://www.python.org/downloads/)
18
+ [![PyPI version](https://badge.fury.io/py/docstring-generator.svg)](https://badge.fury.io/py/docstring-generator)
19
+ [![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)
20
+ [![uv](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/uv/main/assets/badge/v0.json)](https://github.com/astral-sh/uv)
21
+ [![](https://img.shields.io/pypi/dm/docstring-generator.svg)](https://pypi.org/project/docstring-generator/)
22
+
23
+ # docstring_generator
24
+ Auto generate docstring from type-hints for python functions and class methods.
25
+
26
+ ## How to use it
27
+
28
+ ```shell
29
+ gendocs_new file.py
30
+ ```
31
+
32
+ ```shell
33
+ gendocs_new mydir/
34
+ ```
35
+
36
+ ## Options
37
+
38
+ ### style
39
+
40
+ - `--style`
41
+ - Docstring style [numpy, google, rest]. [default: numpy]
42
+
43
+ ### Add additional information before running `gendocs_new`
44
+
45
+ - when adding `$<num>` into your docstring these will then be replaced with parameter at this index
46
+ - Example:
47
+ ```python
48
+ from typing import List
49
+
50
+
51
+ def foo(val_a: int, val_b: List[int]):
52
+ """
53
+ Lorem ipsum dolor sit amet, consetetur sadipscing elitr,
54
+ sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam
55
+
56
+ $1 Lorem ipsum dolor sit amet
57
+ $2 nonumy eirmod tempor invidun
58
+ """
59
+ ```
60
+ will become (here with numpy style)
61
+ ```python
62
+ from typing import List
63
+
64
+
65
+ def foo(val_a: int, val_b: List[int]):
66
+ """
67
+ Lorem ipsum dolor sit amet, consetetur sadipscing elitr,
68
+ sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam
69
+
70
+ Parameters
71
+ ----------
72
+ val_a : argument of type int
73
+ Lorem ipsum dolor sit amet
74
+ val_b : argument of type List(int)
75
+ nonumy eirmod tempor invidun
76
+
77
+ """
78
+ ```
79
+
80
+ ## FAQ
81
+
82
+ ### what happens if I re-run the docstring creation?
83
+
84
+ - nothing if all stays the same, changed parameter descriptions will be ignored only changes of the function header will be used
85
+
86
+ ## Examples
87
+ - An example can be found under examples
88
+
89
+ ## Installing
90
+
91
+ - pip install docstring-generator
92
+
93
+ ## Dependency
94
+
95
+ - [docstring-generator-ext](https://github.com/FelixTheC/docstring_generator_ext)
96
+ - this extension is the heart of this project and written with pybind11 (c++)
97
+
98
+ ## Versioning
99
+
100
+ - For the versions available, see the tags on this repository.
101
+
102
+ ## Authors
103
+
104
+ - Felix Eisenmenger
105
+
106
+ ## License
107
+
108
+ - MIT License (MIT)
@@ -0,0 +1,92 @@
1
+ [![Python 3.10](https://img.shields.io/badge/python-3-blue.svg)](https://www.python.org/downloads/)
2
+ [![PyPI version](https://badge.fury.io/py/docstring-generator.svg)](https://badge.fury.io/py/docstring-generator)
3
+ [![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)
4
+ [![uv](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/uv/main/assets/badge/v0.json)](https://github.com/astral-sh/uv)
5
+ [![](https://img.shields.io/pypi/dm/docstring-generator.svg)](https://pypi.org/project/docstring-generator/)
6
+
7
+ # docstring_generator
8
+ Auto generate docstring from type-hints for python functions and class methods.
9
+
10
+ ## How to use it
11
+
12
+ ```shell
13
+ gendocs_new file.py
14
+ ```
15
+
16
+ ```shell
17
+ gendocs_new mydir/
18
+ ```
19
+
20
+ ## Options
21
+
22
+ ### style
23
+
24
+ - `--style`
25
+ - Docstring style [numpy, google, rest]. [default: numpy]
26
+
27
+ ### Add additional information before running `gendocs_new`
28
+
29
+ - when adding `$<num>` into your docstring these will then be replaced with parameter at this index
30
+ - Example:
31
+ ```python
32
+ from typing import List
33
+
34
+
35
+ def foo(val_a: int, val_b: List[int]):
36
+ """
37
+ Lorem ipsum dolor sit amet, consetetur sadipscing elitr,
38
+ sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam
39
+
40
+ $1 Lorem ipsum dolor sit amet
41
+ $2 nonumy eirmod tempor invidun
42
+ """
43
+ ```
44
+ will become (here with numpy style)
45
+ ```python
46
+ from typing import List
47
+
48
+
49
+ def foo(val_a: int, val_b: List[int]):
50
+ """
51
+ Lorem ipsum dolor sit amet, consetetur sadipscing elitr,
52
+ sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam
53
+
54
+ Parameters
55
+ ----------
56
+ val_a : argument of type int
57
+ Lorem ipsum dolor sit amet
58
+ val_b : argument of type List(int)
59
+ nonumy eirmod tempor invidun
60
+
61
+ """
62
+ ```
63
+
64
+ ## FAQ
65
+
66
+ ### what happens if I re-run the docstring creation?
67
+
68
+ - nothing if all stays the same, changed parameter descriptions will be ignored only changes of the function header will be used
69
+
70
+ ## Examples
71
+ - An example can be found under examples
72
+
73
+ ## Installing
74
+
75
+ - pip install docstring-generator
76
+
77
+ ## Dependency
78
+
79
+ - [docstring-generator-ext](https://github.com/FelixTheC/docstring_generator_ext)
80
+ - this extension is the heart of this project and written with pybind11 (c++)
81
+
82
+ ## Versioning
83
+
84
+ - For the versions available, see the tags on this repository.
85
+
86
+ ## Authors
87
+
88
+ - Felix Eisenmenger
89
+
90
+ ## License
91
+
92
+ - MIT License (MIT)
@@ -0,0 +1,51 @@
1
+ [project]
2
+ name = "docstring-generator"
3
+ version = "1.0.2"
4
+ description = "Auto generate docstring from type-hints."
5
+ authors = [
6
+ { name = "FelixTheC" },
7
+ ]
8
+ readme = "README.md"
9
+ requires-python = ">=3.13"
10
+
11
+ classifiers=[
12
+ "Environment :: Console",
13
+ "Programming Language :: Python :: 3",
14
+ "Topic :: Utilities",
15
+ "Topic :: Software Development :: Documentation",
16
+ "Typing :: Typed",
17
+ ]
18
+
19
+ dependencies = [
20
+ "click >= 8.1.3",
21
+ "docstring-generator-ext>=1.0.2",
22
+ ]
23
+
24
+ [dependency-groups]
25
+ dev = [
26
+ "pytest>=9.0.3",
27
+ "pytest-cov>=7.1.0",
28
+ "ruff>=0.15.12",
29
+ ]
30
+
31
+ [tool.poetry.group.dev.dependencies]
32
+ black = ">=22.8,<25.0"
33
+ isort = "^5.10.1"
34
+ pytest = "^7.1.3"
35
+
36
+ [project.urls]
37
+ Repository = "https://github.com/FelixTheC/docstring_generator"
38
+
39
+ [build-system]
40
+ requires = ["setuptools>=61.0", "wheel"]
41
+ build-backend = "setuptools.build_meta"
42
+
43
+ # --- TOOL CONFIGS ---
44
+ [tool.ruff]
45
+ line-length = 100
46
+ target-version = "py313"
47
+ src = ["src"]
48
+ exclude = ["tests"]
49
+
50
+ [project.scripts]
51
+ gendocs_new = "docstring_generator.new_gen_docs:main"
@@ -0,0 +1,4 @@
1
+ [egg_info]
2
+ tag_build =
3
+ tag_date = 0
4
+
@@ -0,0 +1,108 @@
1
+ Metadata-Version: 2.4
2
+ Name: docstring-generator
3
+ Version: 1.0.2
4
+ Summary: Auto generate docstring from type-hints.
5
+ Author: FelixTheC
6
+ Project-URL: Repository, https://github.com/FelixTheC/docstring_generator
7
+ Classifier: Environment :: Console
8
+ Classifier: Programming Language :: Python :: 3
9
+ Classifier: Topic :: Utilities
10
+ Classifier: Topic :: Software Development :: Documentation
11
+ Classifier: Typing :: Typed
12
+ Requires-Python: >=3.13
13
+ Description-Content-Type: text/markdown
14
+ Requires-Dist: click>=8.1.3
15
+ Requires-Dist: docstring-generator-ext>=1.0.2
16
+
17
+ [![Python 3.10](https://img.shields.io/badge/python-3-blue.svg)](https://www.python.org/downloads/)
18
+ [![PyPI version](https://badge.fury.io/py/docstring-generator.svg)](https://badge.fury.io/py/docstring-generator)
19
+ [![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)
20
+ [![uv](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/uv/main/assets/badge/v0.json)](https://github.com/astral-sh/uv)
21
+ [![](https://img.shields.io/pypi/dm/docstring-generator.svg)](https://pypi.org/project/docstring-generator/)
22
+
23
+ # docstring_generator
24
+ Auto generate docstring from type-hints for python functions and class methods.
25
+
26
+ ## How to use it
27
+
28
+ ```shell
29
+ gendocs_new file.py
30
+ ```
31
+
32
+ ```shell
33
+ gendocs_new mydir/
34
+ ```
35
+
36
+ ## Options
37
+
38
+ ### style
39
+
40
+ - `--style`
41
+ - Docstring style [numpy, google, rest]. [default: numpy]
42
+
43
+ ### Add additional information before running `gendocs_new`
44
+
45
+ - when adding `$<num>` into your docstring these will then be replaced with parameter at this index
46
+ - Example:
47
+ ```python
48
+ from typing import List
49
+
50
+
51
+ def foo(val_a: int, val_b: List[int]):
52
+ """
53
+ Lorem ipsum dolor sit amet, consetetur sadipscing elitr,
54
+ sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam
55
+
56
+ $1 Lorem ipsum dolor sit amet
57
+ $2 nonumy eirmod tempor invidun
58
+ """
59
+ ```
60
+ will become (here with numpy style)
61
+ ```python
62
+ from typing import List
63
+
64
+
65
+ def foo(val_a: int, val_b: List[int]):
66
+ """
67
+ Lorem ipsum dolor sit amet, consetetur sadipscing elitr,
68
+ sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam
69
+
70
+ Parameters
71
+ ----------
72
+ val_a : argument of type int
73
+ Lorem ipsum dolor sit amet
74
+ val_b : argument of type List(int)
75
+ nonumy eirmod tempor invidun
76
+
77
+ """
78
+ ```
79
+
80
+ ## FAQ
81
+
82
+ ### what happens if I re-run the docstring creation?
83
+
84
+ - nothing if all stays the same, changed parameter descriptions will be ignored only changes of the function header will be used
85
+
86
+ ## Examples
87
+ - An example can be found under examples
88
+
89
+ ## Installing
90
+
91
+ - pip install docstring-generator
92
+
93
+ ## Dependency
94
+
95
+ - [docstring-generator-ext](https://github.com/FelixTheC/docstring_generator_ext)
96
+ - this extension is the heart of this project and written with pybind11 (c++)
97
+
98
+ ## Versioning
99
+
100
+ - For the versions available, see the tags on this repository.
101
+
102
+ ## Authors
103
+
104
+ - Felix Eisenmenger
105
+
106
+ ## License
107
+
108
+ - MIT License (MIT)
@@ -0,0 +1,10 @@
1
+ README.md
2
+ pyproject.toml
3
+ src/docstring_generator/__init__.py
4
+ src/docstring_generator/new_gen_docs.py
5
+ src/docstring_generator.egg-info/PKG-INFO
6
+ src/docstring_generator.egg-info/SOURCES.txt
7
+ src/docstring_generator.egg-info/dependency_links.txt
8
+ src/docstring_generator.egg-info/entry_points.txt
9
+ src/docstring_generator.egg-info/requires.txt
10
+ src/docstring_generator.egg-info/top_level.txt
@@ -0,0 +1,2 @@
1
+ [console_scripts]
2
+ gendocs_new = docstring_generator.new_gen_docs:main
@@ -0,0 +1,2 @@
1
+ click>=8.1.3
2
+ docstring-generator-ext>=1.0.2
@@ -0,0 +1 @@
1
+ docstring_generator
@@ -1,36 +0,0 @@
1
- Metadata-Version: 2.1
2
- Name: docstring-generator
3
- Version: 0.3.4
4
- Summary: Auto generate docstring from type-hints.
5
- Home-page: https://github.com/FelixTheC/docstring_generator
6
- License: MIT
7
- Author: FelixTheC
8
- Author-email: felixeisenmenger@gmx.net
9
- Requires-Python: >=3.8,<=3.11
10
- Classifier: Development Status :: 4 - Beta
11
- Classifier: Environment :: Console
12
- Classifier: License :: OSI Approved :: MIT License
13
- Classifier: Programming Language :: Python :: 3
14
- Classifier: Programming Language :: Python :: 3.8
15
- Classifier: Programming Language :: Python :: 3.9
16
- Classifier: Programming Language :: Python :: 3.10
17
- Classifier: Programming Language :: Python :: 3
18
- Classifier: Programming Language :: Python :: 3.10
19
- Classifier: Programming Language :: Python :: 3.9
20
- Classifier: Topic :: Software Development :: Documentation
21
- Classifier: Topic :: Utilities
22
- Classifier: Typing :: Typed
23
- Requires-Dist: click (>=8.1.3,<9.0.0)
24
- Requires-Dist: docstring-generator-ext (>=0.0.33)
25
- Project-URL: Repository, https://github.com/FelixTheC/docstring_generator
26
- Description-Content-Type: text/markdown
27
-
28
- #### Versioning
29
- - For the versions available, see the tags on this repository.
30
-
31
- ### Authors
32
- - Felix Eisenmenger
33
-
34
- ### License
35
- - This project is licensed under the MIT License - see the LICENSE.md file for details
36
-
@@ -1,8 +0,0 @@
1
- #### Versioning
2
- - For the versions available, see the tags on this repository.
3
-
4
- ### Authors
5
- - Felix Eisenmenger
6
-
7
- ### License
8
- - This project is licensed under the MIT License - see the LICENSE.md file for details
@@ -1,46 +0,0 @@
1
- [tool.black]
2
- line-length = 100
3
- target-version = ['py39']
4
-
5
- [tool.isort]
6
- combine_as_imports = true
7
- line_length = 100
8
- profile = "black"
9
-
10
- [tool.poetry]
11
- name = "docstring-generator"
12
- version = "0.3.4"
13
- description = "Auto generate docstring from type-hints."
14
- authors = ["FelixTheC <felixeisenmenger@gmx.net>"]
15
- readme = "README.md"
16
- license = "MIT"
17
- repository = "https://github.com/FelixTheC/docstring_generator"
18
- packages = [{include = "docstring_generator"}]
19
- classifiers=[
20
- "Development Status :: 4 - Beta",
21
- "Environment :: Console",
22
- "License :: OSI Approved :: MIT License",
23
- "Programming Language :: Python :: 3",
24
- "Programming Language :: Python :: 3.9",
25
- "Programming Language :: Python :: 3.10",
26
- "Topic :: Utilities",
27
- "Topic :: Software Development :: Documentation",
28
- "Typing :: Typed",
29
- ]
30
-
31
- [tool.poetry.scripts]
32
- gendocs_new = "docstring_generator.new_gen_docs:main"
33
-
34
- [tool.poetry.dependencies]
35
- python = ">=3.8,<=3.11"
36
- click = "^8.1.3"
37
- docstring-generator-ext = ">=0.0.33"
38
-
39
- [tool.poetry.group.dev.dependencies]
40
- black = "^22.8.0"
41
- isort = "^5.10.1"
42
- pytest = "^7.1.3"
43
-
44
- [build-system]
45
- requires = ["poetry-core"]
46
- build-backend = "poetry.core.masonry.api"
@@ -1,34 +0,0 @@
1
- # -*- coding: utf-8 -*-
2
- from setuptools import setup
3
-
4
- packages = \
5
- ['docstring_generator']
6
-
7
- package_data = \
8
- {'': ['*']}
9
-
10
- install_requires = \
11
- ['click>=8.1.3,<9.0.0', 'docstring-generator-ext>=0.0.33']
12
-
13
- entry_points = \
14
- {'console_scripts': ['gendocs_new = docstring_generator.new_gen_docs:main']}
15
-
16
- setup_kwargs = {
17
- 'name': 'docstring-generator',
18
- 'version': '0.3.4',
19
- 'description': 'Auto generate docstring from type-hints.',
20
- 'long_description': '#### Versioning\n- For the versions available, see the tags on this repository.\n\n### Authors\n- Felix Eisenmenger\n\n### License\n- This project is licensed under the MIT License - see the LICENSE.md file for details\n',
21
- 'author': 'FelixTheC',
22
- 'author_email': 'felixeisenmenger@gmx.net',
23
- 'maintainer': 'None',
24
- 'maintainer_email': 'None',
25
- 'url': 'https://github.com/FelixTheC/docstring_generator',
26
- 'packages': packages,
27
- 'package_data': package_data,
28
- 'install_requires': install_requires,
29
- 'entry_points': entry_points,
30
- 'python_requires': '>=3.8,<=3.11',
31
- }
32
-
33
-
34
- setup(**setup_kwargs)