File tree Expand file tree Collapse file tree 1 file changed +9
-3
lines changed
Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Original file line number Diff line number Diff line change 77import pdoc
88from packaging import version
99
10- sys .path .insert (0 , os .path .join (os .path .dirname (__file__ ), '../screen_brightness_control' ))
11- from _version import __version__ # noqa: E402
12-
1310HERE = Path (__file__ ).parent
1411TEMPLATES = HERE / 'templates'
1512OUTPUT_DIR = HERE / 'docs'
13+
14+ if os .path .isfile (HERE / '..' / 'screen_brightness_control' / '_version.py' ):
15+ sys .path .insert (0 , str (HERE / '..' / 'screen_brightness_control' ))
16+ from _version import __version__ # noqa: E402
17+ else :
18+ sys .path .insert (0 , str (HERE / '..' ))
19+ from screen_brightness_control import __version__
20+
21+
1622pdoc .docstrings .GOOGLE_LIST_SECTIONS .extend (["Returns" , "Yields" ])
1723pdoc .render .configure (docformat = 'google' , template_directory = TEMPLATES , footer_text = f'screen_brightness_control v{ __version__ } ' ) # noqa: E501
1824
You can’t perform that action at this time.
0 commit comments