70 lines
No EOL
1.3 KiB
Batchfile
70 lines
No EOL
1.3 KiB
Batchfile
@echo off
|
|
pushd %~dp0
|
|
|
|
set outputFile="cs_outputUS.txt"
|
|
set errorsFile="cs_errorsUS.txt"
|
|
set chmFile="chm\helpUbiServicesCS.chm"
|
|
|
|
call :clean_dir
|
|
|
|
mkdir chm 2>nul
|
|
|
|
echo on
|
|
call ..\external\tools\python\python-3.5.1-embed-amd64\python.exe .\cs_comments.py
|
|
@echo off
|
|
if ERRORLEVEL 1 (
|
|
echo.
|
|
echo cs_comments.py failed. Check for unsupported characters or unbalanced parenthesis in your comments.
|
|
echo.
|
|
goto :exit_error
|
|
)
|
|
|
|
echo on
|
|
call ..\external\tools\doxygen\bin\doxygen cs_doxyfileUS >%outputFile% 2>%errorsFile%
|
|
@echo off
|
|
|
|
REM deleting errors file if empty and chm file was generated.
|
|
for %%A in (%errorsFile%) do (
|
|
if %%~zA == 0 (
|
|
if exist %chmFile% (
|
|
del %errorsFile%
|
|
goto :exit_success
|
|
)
|
|
)
|
|
)
|
|
|
|
if not exist %chmFile% (
|
|
echo %chmFile% was not generated.
|
|
echo.
|
|
)
|
|
|
|
echo Content of %errorsFile% file:
|
|
echo.
|
|
type %errorsFile%
|
|
echo.
|
|
|
|
goto :exit_error
|
|
|
|
|
|
:exit_success
|
|
echo Documentation generation succeeded.
|
|
echo.
|
|
call :clean_dir
|
|
popd
|
|
exit /b 0
|
|
|
|
:exit_error
|
|
echo Documentation generation failed.
|
|
echo.
|
|
call :clean_dir
|
|
popd
|
|
exit /b 1
|
|
|
|
:clean_dir
|
|
del /Q html\*.* 2>nul
|
|
del /Q latex\*.* 2>nul
|
|
del /Q temp_headers\*.* 2>nul
|
|
rmdir html 2>nul
|
|
rmdir latex 2>nul
|
|
rmdir temp_headers /s/q 2>nul
|
|
exit /b |