|
1 | | -# Configuration file for the Sphinx documentation builder. |
2 | | -# |
3 | | -# This file only contains a selection of the most common options. For a full |
4 | | -# list see the documentation: |
5 | | -# https://www.sphinx-doc.org/en/master/usage/configuration.html |
6 | | -import inspect |
7 | | -# -- Path setup -------------------------------------------------------------- |
| 1 | +# Configuration file for Sphinx documentation builder |
8 | 2 |
|
9 | | -# If extensions (or modules to document with autodoc) are in another directory, |
10 | | -# add these directories to sys.path here. If the directory is relative to the |
11 | | -# documentation root, use os.path.abspath to make it absolute, like shown here. |
12 | | -# |
13 | | -# import os |
14 | | -# import sys |
15 | 3 | import os |
16 | 4 | import sys |
17 | 5 |
|
18 | | -sys.path.insert(0, os.path.abspath('.')) |
19 | | - |
20 | | -currentdir = os.path.dirname(os.path.abspath(inspect.getfile(inspect.currentframe()))) |
21 | | -parentdir = os.path.dirname(currentdir) |
22 | | -sys.path.insert(0, parentdir) |
23 | | - |
24 | | -# Importar el módulo principal - ¡ESTO ES CLAVE Y DIFERENTE A LO QUE HEMOS HECHO! |
25 | | -import ad_api |
| 6 | +# Agregar directorio padre al path |
| 7 | +sys.path.insert(0, os.path.abspath('..')) |
26 | 8 |
|
27 | 9 | # -- Project information ----------------------------------------------------- |
28 | | - |
29 | | -project = 'PYTHON-AMAZON-AD-API' |
| 10 | +project = 'Python Amazon Advertising API' |
30 | 11 | copyright = '2023, Daniel Alvaro' |
31 | 12 | author = 'Daniel Alvaro' |
| 13 | +release = '0.7.4' |
| 14 | +version = '0.7.4' |
32 | 15 |
|
33 | 16 | # -- General configuration --------------------------------------------------- |
34 | | - |
35 | | -# Add any Sphinx extension module names here, as strings. They can be |
36 | | -# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom |
37 | | -# ones. |
38 | 17 | extensions = [ |
39 | | - "sphinx_rtd_theme", 'button', 'cookieconsent', |
40 | | - 'sphinx.ext.autodoc', 'sphinx.ext.coverage', 'sphinx.ext.napoleon', |
41 | | - 'enum_tools.autoenum', |
42 | | - |
| 18 | + 'sphinx.ext.autodoc', |
| 19 | + 'sphinx.ext.napoleon', # Para docstrings estilo Google |
| 20 | + 'sphinx_rtd_theme', |
43 | 21 | ] |
44 | 22 |
|
45 | | -# Add any paths that contain templates here, relative to this directory. |
46 | | -templates_path = ['_templates'] |
47 | | - |
48 | | -# List of patterns, relative to source directory, that match files and |
49 | | -# directories to ignore when looking for source files. |
50 | | -# This pattern also affects html_static_path and html_extra_path. |
51 | | -exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store'] |
52 | | -autodoc_default_options = {"members": True, "undoc-members": True, 'member-order': 'bysource'} |
53 | | -# html_theme_options = { |
54 | | -# "collapse_navigation": False |
55 | | -# } |
56 | | -# -- Options for HTML output ------------------------------------------------- |
57 | | - |
58 | | -# The theme to use for HTML and HTML Help pages. See the documentation for |
59 | | -# a list of builtin themes. |
60 | | -# |
61 | | -# html_theme = 'sphinx_rtd_theme' |
62 | | -# html_theme = "pydata_sphinx_theme" |
63 | | -html_theme = 'alabaster' |
64 | | - |
65 | | -html_theme_options = { |
66 | | - 'github_button': True, # optional tweaks |
67 | | - 'github_banner': True, |
68 | | - 'github_button': True, |
69 | | - 'description': ''' |
70 | | -A wrapper to access Amazon's Advertising API with an easy-to-use interface. |
71 | | - ''', |
72 | | - 'donate_url': 'https://github.com/sponsors/denisneuf', |
73 | | - 'github_user': 'denisneuf', |
74 | | - 'github_repo': 'python-amazon-ad-api', |
75 | | - "github_type": "star", # watch|star|fork |
76 | | -'fixed_sidebar': True |
| 23 | +# Configuración MINIMAL pero FUNCIONAL |
| 24 | +autodoc_default_options = { |
| 25 | + 'members': True, |
| 26 | + 'undoc-members': True, |
| 27 | + 'member-order': 'bysource', |
77 | 28 | } |
78 | | -# Add any paths that contain custom static files (such as style sheets) here, |
79 | | -relative to this directory. They are copied after the builtin static files, |
80 | | -so a file named "default.css" will overwrite the builtin "default.css". |
81 | | -html_static_path = ['_static'] |
82 | | -html_css_files = ['custom.css'] |
83 | 29 |
|
| 30 | +# IMPORTANTE para métodos decorados |
| 31 | +autodoc_inherit_docstrings = True |
84 | 32 |
|
| 33 | +# Configuración de napoleon |
85 | 34 | napoleon_google_docstring = True |
86 | 35 | napoleon_numpy_docstring = False |
| 36 | + |
| 37 | +templates_path = ['_templates'] |
| 38 | +exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store'] |
| 39 | + |
| 40 | +# -- Options for HTML output ------------------------------------------------- |
| 41 | +html_theme = 'sphinx_rtd_theme' |
| 42 | +html_static_path = ['_static'] |
0 commit comments