docs: add Windows make file (#1222)

This commit is contained in:
ReenigneArcher 2023-08-28 12:41:11 -04:00 committed by GitHub
parent 103bc6f8ef
commit dba3369f55
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 35 additions and 4 deletions

35
docs/make.bat Normal file
View file

@ -0,0 +1,35 @@
@ECHO OFF
pushd %~dp0
REM Command file for Sphinx documentation
if "%SPHINXBUILD%" == "" (
set SPHINXBUILD=sphinx-build
)
set SOURCEDIR=.
set BUILDDIR=_build
%SPHINXBUILD% >NUL 2>NUL
if errorlevel 9009 (
echo.
echo.The 'sphinx-build' command was not found. Make sure you have Sphinx
echo.installed, then set the SPHINXBUILD environment variable to point
echo.to the full path of the 'sphinx-build' executable. Alternatively you
echo.may add the Sphinx directory to PATH.
echo.
echo.If you don't have Sphinx installed, grab it from
echo.https://www.sphinx-doc.org/
exit /b 1
)
if "%1" == "" goto help
%SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%
goto end
:help
%SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%
:end
popd

View file

@ -1,15 +1,11 @@
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
import os
import shlex import shlex
import subprocess import subprocess
from os.path import abspath, dirname, join from os.path import abspath, dirname, join
import pytest
SKIP_EXAMPLES = ["Example 4"] SKIP_EXAMPLES = ["Example 4"]
@pytest.mark.skipif(os.name == "nt", reason="No make.bat specified for Windows")
def test_build_documentation(): def test_build_documentation():
docroot = join(dirname(dirname(abspath(__file__))), "docs") docroot = join(dirname(dirname(abspath(__file__))), "docs")
cmd = shlex.split("sphinx-build -aE . _build") cmd = shlex.split("sphinx-build -aE . _build")