Skip to content

Conversation

@Revathyvenugopal162
Copy link
Contributor

@Revathyvenugopal162 Revathyvenugopal162 commented Mar 6, 2025

This PR introduces a new Tox environment, [testenv:doc-serve], to build and serve the documentation locally.

  1. Adds [testenv:doc-serve] to build and serve docs locally.
  2. Uses stb serve for live preview.
  3. Includes necessary dependencies and environment setup.
  4. Helps in testing documentation changes more efficiently.

@Revathyvenugopal162 Revathyvenugopal162 requested a review from a team as a code owner March 6, 2025 10:00
@github-actions github-actions bot added enhancement General improvements to existing features documentation labels Mar 6, 2025
Copy link
Member

@jorgepiloto jorgepiloto left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for adding this, @Revathyvenugopal162. Just left one comment for adding this environment to the doc group and renaming it.

tox.ini Outdated
python -m build {toxinidir}
python -m build {toxinidir}

[testenv:doc-preview]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's add this with the rest of the doc environments and rename it serve. This is the usual name:

[testenv:doc-{clean,links,html,pdf,serve}]

skip_install:
    clean,serve: true

commands = 
    ...
    serve: stb serve "{toxinidir}/{env:BUILD_DIR}/html" --open-browser

Copy link
Member

@jorgepiloto jorgepiloto left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just left one suggestion regarding the deps.

tox.ini Outdated
Comment on lines 42 to 43
deps=
serve: sphinx-theme-builder[cli] @ https://github.com/pradyunsg/sphinx-theme-builder/archive/d9f620b1a73839728c95b596343595d3952ec8bf.zip
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not required. The build system is already installing the STB tool.

@jorgepiloto jorgepiloto added this to the ansys-sphinx-theme v1.4 milestone Mar 6, 2025
@Revathyvenugopal162 Revathyvenugopal162 enabled auto-merge (squash) March 6, 2025 15:26
@Revathyvenugopal162 Revathyvenugopal162 merged commit ac8e287 into main Mar 6, 2025
21 checks passed
@Revathyvenugopal162 Revathyvenugopal162 deleted the feat/add-tox-preview branch March 6, 2025 15:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement General improvements to existing features

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants