fix help message
[rainbowstream.git] / docs / make.bat
CommitLineData
c264071c 1@ECHO OFF\r
2\r
3REM Command file for Sphinx documentation\r
4\r
5if "%SPHINXBUILD%" == "" (\r
6 set SPHINXBUILD=sphinx-build\r
7)\r
8set BUILDDIR=_build\r
9set ALLSPHINXOPTS=-d %BUILDDIR%/doctrees %SPHINXOPTS% .\r
10set I18NSPHINXOPTS=%SPHINXOPTS% .\r
11if NOT "%PAPER%" == "" (\r
12 set ALLSPHINXOPTS=-D latex_paper_size=%PAPER% %ALLSPHINXOPTS%\r
13 set I18NSPHINXOPTS=-D latex_paper_size=%PAPER% %I18NSPHINXOPTS%\r
14)\r
15\r
16if "%1" == "" goto help\r
17\r
18if "%1" == "help" (\r
19 :help\r
20 echo.Please use `make ^<target^>` where ^<target^> is one of\r
21 echo. html to make standalone HTML files\r
22 echo. dirhtml to make HTML files named index.html in directories\r
23 echo. singlehtml to make a single large HTML file\r
24 echo. pickle to make pickle files\r
25 echo. json to make JSON files\r
26 echo. htmlhelp to make HTML files and a HTML help project\r
27 echo. qthelp to make HTML files and a qthelp project\r
28 echo. devhelp to make HTML files and a Devhelp project\r
29 echo. epub to make an epub\r
30 echo. latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter\r
31 echo. text to make text files\r
32 echo. man to make manual pages\r
33 echo. texinfo to make Texinfo files\r
34 echo. gettext to make PO message catalogs\r
35 echo. changes to make an overview over all changed/added/deprecated items\r
36 echo. xml to make Docutils-native XML files\r
37 echo. pseudoxml to make pseudoxml-XML files for display purposes\r
38 echo. linkcheck to check all external links for integrity\r
39 echo. doctest to run all doctests embedded in the documentation if enabled\r
40 goto end\r
41)\r
42\r
43if "%1" == "clean" (\r
44 for /d %%i in (%BUILDDIR%\*) do rmdir /q /s %%i\r
45 del /q /s %BUILDDIR%\*\r
46 goto end\r
47)\r
48\r
49\r
50%SPHINXBUILD% 2> nul\r
51if errorlevel 9009 (\r
52 echo.\r
53 echo.The 'sphinx-build' command was not found. Make sure you have Sphinx\r
54 echo.installed, then set the SPHINXBUILD environment variable to point\r
55 echo.to the full path of the 'sphinx-build' executable. Alternatively you\r
56 echo.may add the Sphinx directory to PATH.\r
57 echo.\r
58 echo.If you don't have Sphinx installed, grab it from\r
59 echo.http://sphinx-doc.org/\r
60 exit /b 1\r
61)\r
62\r
63if "%1" == "html" (\r
64 %SPHINXBUILD% -b html %ALLSPHINXOPTS% %BUILDDIR%/html\r
65 if errorlevel 1 exit /b 1\r
66 echo.\r
67 echo.Build finished. The HTML pages are in %BUILDDIR%/html.\r
68 goto end\r
69)\r
70\r
71if "%1" == "dirhtml" (\r
72 %SPHINXBUILD% -b dirhtml %ALLSPHINXOPTS% %BUILDDIR%/dirhtml\r
73 if errorlevel 1 exit /b 1\r
74 echo.\r
75 echo.Build finished. The HTML pages are in %BUILDDIR%/dirhtml.\r
76 goto end\r
77)\r
78\r
79if "%1" == "singlehtml" (\r
80 %SPHINXBUILD% -b singlehtml %ALLSPHINXOPTS% %BUILDDIR%/singlehtml\r
81 if errorlevel 1 exit /b 1\r
82 echo.\r
83 echo.Build finished. The HTML pages are in %BUILDDIR%/singlehtml.\r
84 goto end\r
85)\r
86\r
87if "%1" == "pickle" (\r
88 %SPHINXBUILD% -b pickle %ALLSPHINXOPTS% %BUILDDIR%/pickle\r
89 if errorlevel 1 exit /b 1\r
90 echo.\r
91 echo.Build finished; now you can process the pickle files.\r
92 goto end\r
93)\r
94\r
95if "%1" == "json" (\r
96 %SPHINXBUILD% -b json %ALLSPHINXOPTS% %BUILDDIR%/json\r
97 if errorlevel 1 exit /b 1\r
98 echo.\r
99 echo.Build finished; now you can process the JSON files.\r
100 goto end\r
101)\r
102\r
103if "%1" == "htmlhelp" (\r
104 %SPHINXBUILD% -b htmlhelp %ALLSPHINXOPTS% %BUILDDIR%/htmlhelp\r
105 if errorlevel 1 exit /b 1\r
106 echo.\r
107 echo.Build finished; now you can run HTML Help Workshop with the ^\r
108.hhp project file in %BUILDDIR%/htmlhelp.\r
109 goto end\r
110)\r
111\r
112if "%1" == "qthelp" (\r
113 %SPHINXBUILD% -b qthelp %ALLSPHINXOPTS% %BUILDDIR%/qthelp\r
114 if errorlevel 1 exit /b 1\r
115 echo.\r
116 echo.Build finished; now you can run "qcollectiongenerator" with the ^\r
117.qhcp project file in %BUILDDIR%/qthelp, like this:\r
118 echo.^> qcollectiongenerator %BUILDDIR%\qthelp\RainbowStream.qhcp\r
119 echo.To view the help file:\r
120 echo.^> assistant -collectionFile %BUILDDIR%\qthelp\RainbowStream.ghc\r
121 goto end\r
122)\r
123\r
124if "%1" == "devhelp" (\r
125 %SPHINXBUILD% -b devhelp %ALLSPHINXOPTS% %BUILDDIR%/devhelp\r
126 if errorlevel 1 exit /b 1\r
127 echo.\r
128 echo.Build finished.\r
129 goto end\r
130)\r
131\r
132if "%1" == "epub" (\r
133 %SPHINXBUILD% -b epub %ALLSPHINXOPTS% %BUILDDIR%/epub\r
134 if errorlevel 1 exit /b 1\r
135 echo.\r
136 echo.Build finished. The epub file is in %BUILDDIR%/epub.\r
137 goto end\r
138)\r
139\r
140if "%1" == "latex" (\r
141 %SPHINXBUILD% -b latex %ALLSPHINXOPTS% %BUILDDIR%/latex\r
142 if errorlevel 1 exit /b 1\r
143 echo.\r
144 echo.Build finished; the LaTeX files are in %BUILDDIR%/latex.\r
145 goto end\r
146)\r
147\r
148if "%1" == "latexpdf" (\r
149 %SPHINXBUILD% -b latex %ALLSPHINXOPTS% %BUILDDIR%/latex\r
150 cd %BUILDDIR%/latex\r
151 make all-pdf\r
152 cd %BUILDDIR%/..\r
153 echo.\r
154 echo.Build finished; the PDF files are in %BUILDDIR%/latex.\r
155 goto end\r
156)\r
157\r
158if "%1" == "latexpdfja" (\r
159 %SPHINXBUILD% -b latex %ALLSPHINXOPTS% %BUILDDIR%/latex\r
160 cd %BUILDDIR%/latex\r
161 make all-pdf-ja\r
162 cd %BUILDDIR%/..\r
163 echo.\r
164 echo.Build finished; the PDF files are in %BUILDDIR%/latex.\r
165 goto end\r
166)\r
167\r
168if "%1" == "text" (\r
169 %SPHINXBUILD% -b text %ALLSPHINXOPTS% %BUILDDIR%/text\r
170 if errorlevel 1 exit /b 1\r
171 echo.\r
172 echo.Build finished. The text files are in %BUILDDIR%/text.\r
173 goto end\r
174)\r
175\r
176if "%1" == "man" (\r
177 %SPHINXBUILD% -b man %ALLSPHINXOPTS% %BUILDDIR%/man\r
178 if errorlevel 1 exit /b 1\r
179 echo.\r
180 echo.Build finished. The manual pages are in %BUILDDIR%/man.\r
181 goto end\r
182)\r
183\r
184if "%1" == "texinfo" (\r
185 %SPHINXBUILD% -b texinfo %ALLSPHINXOPTS% %BUILDDIR%/texinfo\r
186 if errorlevel 1 exit /b 1\r
187 echo.\r
188 echo.Build finished. The Texinfo files are in %BUILDDIR%/texinfo.\r
189 goto end\r
190)\r
191\r
192if "%1" == "gettext" (\r
193 %SPHINXBUILD% -b gettext %I18NSPHINXOPTS% %BUILDDIR%/locale\r
194 if errorlevel 1 exit /b 1\r
195 echo.\r
196 echo.Build finished. The message catalogs are in %BUILDDIR%/locale.\r
197 goto end\r
198)\r
199\r
200if "%1" == "changes" (\r
201 %SPHINXBUILD% -b changes %ALLSPHINXOPTS% %BUILDDIR%/changes\r
202 if errorlevel 1 exit /b 1\r
203 echo.\r
204 echo.The overview file is in %BUILDDIR%/changes.\r
205 goto end\r
206)\r
207\r
208if "%1" == "linkcheck" (\r
209 %SPHINXBUILD% -b linkcheck %ALLSPHINXOPTS% %BUILDDIR%/linkcheck\r
210 if errorlevel 1 exit /b 1\r
211 echo.\r
212 echo.Link check complete; look for any errors in the above output ^\r
213or in %BUILDDIR%/linkcheck/output.txt.\r
214 goto end\r
215)\r
216\r
217if "%1" == "doctest" (\r
218 %SPHINXBUILD% -b doctest %ALLSPHINXOPTS% %BUILDDIR%/doctest\r
219 if errorlevel 1 exit /b 1\r
220 echo.\r
221 echo.Testing of doctests in the sources finished, look at the ^\r
222results in %BUILDDIR%/doctest/output.txt.\r
223 goto end\r
224)\r
225\r
226if "%1" == "xml" (\r
227 %SPHINXBUILD% -b xml %ALLSPHINXOPTS% %BUILDDIR%/xml\r
228 if errorlevel 1 exit /b 1\r
229 echo.\r
230 echo.Build finished. The XML files are in %BUILDDIR%/xml.\r
231 goto end\r
232)\r
233\r
234if "%1" == "pseudoxml" (\r
235 %SPHINXBUILD% -b pseudoxml %ALLSPHINXOPTS% %BUILDDIR%/pseudoxml\r
236 if errorlevel 1 exit /b 1\r
237 echo.\r
238 echo.Build finished. The pseudo-XML files are in %BUILDDIR%/pseudoxml.\r
239 goto end\r
240)\r
241\r
242:end\r