diff --git a/doc/Makefile b/doc/Makefile index ce66465f..fd967771 100644 --- a/doc/Makefile +++ b/doc/Makefile @@ -13,13 +13,6 @@ help: .PHONY: help Makefile -.install-deps: - @pip freeze | grep -q "sphinx-autoapi @ git+https://github.com/ansys/sphinx-autoapi" && is_custom_sphinx_autoapi_installed="yes" || is_custom_sphinx_autoapi_installed="no" - @if [ "$$is_custom_sphinx_autoapi_installed" != "yes" ]; then \ - pip uninstall --yes sphinx-autoapi; \ - pip install "sphinx-autoapi @ git+https://github.com/ansys/sphinx-autoapi@feat/single-page-stable"; \ - fi - # Catch-all target: route all unknown targets to Sphinx using the new # "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). %: Makefile diff --git a/doc/make.bat b/doc/make.bat index 0b80bdf1..64ee4b10 100644 --- a/doc/make.bat +++ b/doc/make.bat @@ -10,13 +10,6 @@ if "%SPHINXBUILD%" == "" ( set SOURCEDIR=source set BUILDDIR=_build -REM TODO: these lines of code should be removed once the feature branch is merged -for /f %%i in ('pip freeze ^| findstr /c:"sphinx-autoapi @ git+https://github.com/ansys/sphinx-autoapi"') do set is_custom_sphinx_autoapi_installed=%%i -if NOT "%is_custom_sphinx_autoapi_installed%" == "sphinx-autoapi" ( - pip uninstall --yes sphinx-autoapi - pip install "sphinx-autoapi @ git+https://github.com/ansys/sphinx-autoapi@feat/single-page-stable") -REM TODO: these lines of code should be removed once the feature branch is merged - if "%1" == "" goto help if "%1" == "clean" goto clean if "%1" == "pdf" goto pdf diff --git a/doc/source/conf.py b/doc/source/conf.py index f5af14f0..0b5e6d9c 100644 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -15,7 +15,7 @@ from ansys.rocky.core import __version__ # Project information -project = "pyrocky" +project = "ansys-rocky-core" copyright = f"(c) {datetime.now().year} ANSYS, Inc. All rights reserved" author = "ANSYS, Inc." release = version = __version__ @@ -26,6 +26,9 @@ html_theme = "ansys_sphinx_theme" html_short_title = html_title = "pyrocky" +# The name of the Pygments (syntax highlighting) style to use. +pygments_style = "sphinx" + # specify the location of your github repo html_theme_options = { "github_url": "https://github.com/ansys/pyrocky", @@ -39,10 +42,12 @@ "version_match": get_version_match(version), }, "check_switcher": False, + "ansys_sphinx_theme_autoapi": {"project": project}, } # Sphinx extensions extensions = [ + "ansys_sphinx_theme.extension.autoapi", "sphinx.ext.autodoc", "sphinx.ext.autosummary", "numpydoc", @@ -128,13 +133,11 @@ "show-module-summary", "special-members", ] -autoapi_template_dir = get_autoapi_templates_dir_relative_path(Path(__file__)) +autoapi_template_dir = get_autoapi_templates_dir_relative_path(Path(__file__).parent) suppress_warnings = ["autoapi.python_import_resolution"] autoapi_python_use_implicit_namespaces = True autoapi_keep_files = True autoapi_render_in_single_page = ["class", "enum", "exception"] # PyAnsys tags configuration -html_context = { - "pyansys_tags": ['Fluids'] -} +html_context = {"pyansys_tags": ["Fluids"]} diff --git a/doc/source/index.rst b/doc/source/index.rst index ebc1e7e5..448d177d 100644 --- a/doc/source/index.rst +++ b/doc/source/index.rst @@ -41,9 +41,6 @@ the most powerful DEM (discrete element method) software in the market. Explore end-to-end examples that show how to use PyRocky. -.. toctree:: - :hidden: - :maxdepth: 3 .. toctree:: :hidden: :maxdepth: 3 diff --git a/doc/source/user_guide/index.rst b/doc/source/user_guide/index.rst index 5ff2b520..735dd522 100644 --- a/doc/source/user_guide/index.rst +++ b/doc/source/user_guide/index.rst @@ -13,6 +13,7 @@ example, the following code creates a project and saves it to disk: .. vale off .. code:: python + rocky = pyrocky.launch_rocky() api = rocky.api diff --git a/pyproject.toml b/pyproject.toml index 8136fadd..9405d3ee 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -25,7 +25,7 @@ dependencies = [ "importlib-metadata>=4.0", "Pyro5>=5.13", "numpy>=1.19, <3.0", - "ansys-tools-common", + "ansys-tools-common>=0.3.1", "click==8.3.1", # clink 8.2.0 is failing the license check. ] @@ -36,10 +36,9 @@ tests = [ "requests==2.32.5", ] doc = [ - "ansys-sphinx-theme==1.6.3", + "ansys-sphinx-theme[autoapi]==1.6.3", "numpydoc==1.9.0", - "Sphinx==8.1.3", - "sphinx-autoapi==3.6.1", + "Sphinx==8.2.3", "sphinx-copybutton==0.5.2", "sphinx-gallery==0.19.0", "sphinx-design==0.6.1",