Skip to content

Commit dc16292

Browse files
authored
Fix error in setup entry points (#466)
* Fix error in setup entry points This was missing from b3225c5 * Add comment about what setup is doing * Optimize python os import * Address Review: Remove uses of os.path
1 parent d24f7ca commit dc16292

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

sphinx_rtd_theme/__init__.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,17 @@
33
From https://github.com/ryan-roemer/sphinx-bootstrap-theme.
44
55
"""
6-
import os
6+
from os import path
77

88
__version__ = '0.2.5b1'
99
__version_full__ = __version__
1010

1111

1212
def get_html_theme_path():
1313
"""Return list of HTML theme paths."""
14-
cur_dir = os.path.abspath(os.path.dirname(os.path.dirname(__file__)))
14+
cur_dir = path.abspath(path.dirname(path.dirname(__file__)))
1515
return cur_dir
16+
17+
# See http://www.sphinx-doc.org/en/stable/theming.html#distribute-your-theme-as-a-python-package
18+
def setup(app):
19+
app.add_html_theme('sphinx_rtd_theme', path.abspath(path.dirname(__file__)))

0 commit comments

Comments
 (0)