2

Is it possible to redefine where sphinx outputs the build files? I want to run a local server (for testing purposes as the documentation is later hosted anyway) and implement some webhook APIs which obviously don't work if I don't have a responding server. So I installed apache and now I want to build to C:/Apache24/htdocs directly. Can I do this?

mzjn
  • 48,958
  • 13
  • 128
  • 248
glades
  • 3,778
  • 1
  • 12
  • 34
  • 1
    See https://www.sphinx-doc.org/en/master/man/sphinx-build.html – mzjn Jan 22 '22 at 11:37
  • Consider using the Sphinx extension https://pypi.org/project/sphinx-autobuild/ for live reload as you edit. Much better than `make build`, then manually refresh the browser. – Steve Piercy Jan 22 '22 at 12:04

2 Answers2

3

What I did was just edit the make.bat file in the docs directory (or where your doc is installed):

set BUILDDIR=your/path/to/build
glades
  • 3,778
  • 1
  • 12
  • 34
0

With your Sphinx project in docs:

sphinx-build docs build

See: https://www.sphinx-doc.org/en/master/man/sphinx-build.html.

wulfgarpro
  • 6,666
  • 12
  • 69
  • 110