Skip to content

Commit

Permalink
Merge pull request #138 from edx/huniafatima/deprecate-edx-sphinx-theme
Browse files Browse the repository at this point in the history
chore: deprecate edx sphinx theme
  • Loading branch information
UsamaSadiq authored Oct 30, 2024
2 parents 9e2d3f1 + 30db1c8 commit 88c179c
Show file tree
Hide file tree
Showing 4 changed files with 72 additions and 16 deletions.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,6 @@ coverage.xml
diff_*.html
*.report
report
venv
acceptance_tests.*.log
acceptance_tests.*.png

Expand Down
55 changes: 47 additions & 8 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
import sys
from subprocess import check_call

import edx_theme
import sphinx_book_theme


def get_version(*file_paths):
Expand Down Expand Up @@ -59,7 +59,7 @@ def get_version(*file_paths):
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
# ones.
extensions = [
'edx_theme',
'sphinx_book_theme',
'sphinx.ext.autodoc',
'sphinx.ext.doctest',
'sphinx.ext.intersphinx',
Expand Down Expand Up @@ -90,8 +90,8 @@ def get_version(*file_paths):

# General information about the project.
project = 'program_intent_engagement'
copyright = edx_theme.COPYRIGHT # pylint: disable=redefined-builtin
author = edx_theme.AUTHOR
copyright = "2024, edX LLC" # pylint: disable=redefined-builtin
author = "edX LLC"
project_title = 'program_intent_engagement'
documentation_title = f"{project_title}"

Expand Down Expand Up @@ -172,16 +172,55 @@ def get_version(*file_paths):
# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.

html_theme = 'edx_theme'
html_theme = 'sphinx_book_theme'

# Theme options are theme-specific and customize the look and feel of a theme
# further. For a list of options available for each theme, see the
# documentation.
#
# html_theme_options = {}
html_theme_options = {

"repository_url": 'https://github.com/edx/program-intent-engagement',
"repository_branch": 'main',
"path_to_docs": "docs/",
"use_repository_button": True,
"use_issues_button": True,
"use_edit_page_button": True,
# Please don't change unless you know what you're doing.
"extra_footer": """
<a rel="license" href="https://creativecommons.org/licenses/by-sa/4.0/">
<img
alt="Creative Commons License"
style="border-width:0"
src="https://i.creativecommons.org/l/by-sa/4.0/80x15.png"/>
</a>
<br>
These works by
<a
xmlns:cc="https://creativecommons.org/ns#"
href="https://edx.org"
property="cc:attributionName"
rel="cc:attributionURL"
>edX LLC</a>
are licensed under a
<a
rel="license"
href="https://creativecommons.org/licenses/by-sa/4.0/"
>Creative Commons Attribution-ShareAlike 4.0 International License</a>.
"""
}

html_logo = "https://logos.openedx.org/open-edx-logo-color.png"
html_favicon = "https://logos.openedx.org/open-edx-favicon.ico"


# Add any paths that contain custom themes here, relative to this directory.
html_theme_path = [edx_theme.get_html_theme_path()]
# Set the DJANGO_SETTINGS_MODULE if it's not set.
# Only if your project has a dependency on Django
if not os.environ.get('DJANGO_SETTINGS_MODULE'):
# If you do depend on django you'll need a settings file that you can
# use when building docs. This will allow you to pull docstrings from
# your code.
os.environ['DJANGO_SETTINGS_MODULE'] = 'test_utils.test_settings'

# The name for this set of Sphinx documents.
# "<project> v<release> documentation" by default.
Expand Down
2 changes: 1 addition & 1 deletion requirements/doc.in
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
-r test.txt # Core and testing dependencies for this package

doc8 # reStructuredText style checker
edx_sphinx_theme # edX theme for Sphinx output
sphinx-book-theme # edX theme for Sphinx output
twine # Validates README.rst for usage on PyPI
build # Needed to build the wheel for twine check
Sphinx # Documentation builder
30 changes: 24 additions & 6 deletions requirements/doc.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
#
# make upgrade
#
accessible-pygments==0.0.4
# via pydata-sphinx-theme
alabaster==0.7.16
# via sphinx
asgiref==3.8.1
Expand All @@ -16,6 +18,8 @@ astroid==3.3.5
# -r requirements/test.txt
# pylint
# pylint-celery
beautifulsoup4==4.12.3
# via pydata-sphinx-theme
babel==2.16.0
# via sphinx
build==1.2.2.post1
Expand Down Expand Up @@ -98,7 +102,6 @@ django==4.2.16
# via
# -c requirements/common_constraints.txt
# -c requirements/constraints.txt
# -r requirements/test.txt
# django-cors-headers
# django-crum
# django-extensions
Expand Down Expand Up @@ -149,6 +152,7 @@ doc8==1.1.2
docutils==0.19
# via
# doc8
# pydata-sphinx-theme
# readme-renderer
# restructuredtext-lint
# sphinx
Expand Down Expand Up @@ -181,8 +185,10 @@ edx-opaque-keys==2.11.0
# edx-drf-extensions
edx-rest-api-client==6.0.0
# via -r requirements/test.txt
edx-sphinx-theme==3.1.0
# via -r requirements/doc.in
exceptiongroup==1.2.2
# via
# -r requirements/test.txt
# pytest
factory-boy==3.3.1
# via -r requirements/test.txt
faker==30.8.0
Expand Down Expand Up @@ -276,6 +282,7 @@ packaging==24.1
# -r requirements/test.txt
# build
# drf-yasg
# pydata-sphinx-theme
# pyproject-api
# pytest
# sphinx
Expand Down Expand Up @@ -305,9 +312,13 @@ pycparser==2.22
# via
# -r requirements/test.txt
# cffi
pydata-sphinx-theme==0.14.4
# via sphinx-book-theme
pygments==2.18.0
# via
# accessible-pygments
# doc8
# pydata-sphinx-theme
# readme-renderer
# rich
# sphinx
Expand Down Expand Up @@ -425,7 +436,6 @@ six==1.16.0
# edx-auth-backends
# edx-django-release-util
# edx-lint
# edx-sphinx-theme
# python-dateutil
snowballstemmer==2.2.0
# via sphinx
Expand All @@ -438,11 +448,16 @@ social-auth-core==4.5.4
# -r requirements/test.txt
# edx-auth-backends
# social-auth-app-django
soupsieve==2.5
# via beautifulsoup4
sphinx==5.3.0
# via
# -r requirements/doc.in
# edx-sphinx-theme
sphinxcontrib-applehelp==2.0.0
# pydata-sphinx-theme
# sphinx-book-theme
sphinx-book-theme==1.0.1
# via -r requirements/doc.in
sphinxcontrib-applehelp==1.0.4
# via sphinx
sphinxcontrib-devhelp==2.0.0
# via sphinx
Expand Down Expand Up @@ -481,6 +496,9 @@ typing-extensions==4.12.2
# via
# -r requirements/test.txt
# edx-opaque-keys
# pydata-sphinx-theme
# pylint
# rich
# faker
uritemplate==4.1.1
# via
Expand Down

0 comments on commit 88c179c

Please sign in to comment.