mirror of
https://github.com/cookiecutter/cookiecutter-django.git
synced 2025-02-16 19:41:03 +03:00
Merge pull request #5347 from ljfp/sphinx-makefile-fix
Fix Makefile and make.bat files used for automatic generation of documentation.
This commit is contained in:
commit
2b375243d0
|
@ -13,11 +13,11 @@ APP = /app
|
||||||
APP = ../{{cookiecutter.project_slug}}
|
APP = ../{{cookiecutter.project_slug}}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
.PHONY: help livehtml apidocs Makefile
|
.PHONY: html livehtml apidocs Makefile
|
||||||
|
|
||||||
# Put it first so that "make" without argument is like "make help".
|
# Put it first so that "make" without argument is like "make html".
|
||||||
help:
|
html:
|
||||||
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) -c .
|
@$(SPHINXBUILD) -M html "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) -c .
|
||||||
|
|
||||||
# Build, watch and serve docs with live reload
|
# Build, watch and serve docs with live reload
|
||||||
livehtml:
|
livehtml:
|
||||||
|
|
|
@ -12,7 +12,7 @@ set SOURCEDIR=_source
|
||||||
set BUILDDIR=_build
|
set BUILDDIR=_build
|
||||||
set APP=..\{{cookiecutter.project_slug}}
|
set APP=..\{{cookiecutter.project_slug}}
|
||||||
|
|
||||||
if "%1" == "" goto help
|
if "%1" == "" goto html
|
||||||
|
|
||||||
%SPHINXBUILD% >NUL 2>NUL
|
%SPHINXBUILD% >NUL 2>NUL
|
||||||
if errorlevel 9009 (
|
if errorlevel 9009 (
|
||||||
|
@ -39,8 +39,8 @@ GOTO :EOF
|
||||||
sphinx-apidoc -o %SOURCEDIR%/api %APP%
|
sphinx-apidoc -o %SOURCEDIR%/api %APP%
|
||||||
GOTO :EOF
|
GOTO :EOF
|
||||||
|
|
||||||
:help
|
:html
|
||||||
%SPHINXBUILD% -b help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%
|
%SPHINXBUILD% -b html %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%
|
||||||
|
|
||||||
:end
|
:end
|
||||||
popd
|
popd
|
||||||
|
|
Loading…
Reference in New Issue
Block a user