Im using Hudson for our HTML assembly, the main reason for using CI is to check the html files during each file using the cse validator. To check the HTML I used the following code
@echo off
PUSHD "F:\Solutions\Documents\Design\html\ValTest"
For %%X in (*.html) do (
"C:\Program Files\HTMLValidator100\cmdlineprocessor" -outputfile output.txt -r1 %%X
set HTMLVAL_ERROR=%ERRORLEVEL%
type output.txt >> result.txt
)
set ERRORLEVEL=%HTMLVAL_ERROR%
POPD
The verification process works fine, but even in the HTML file there is an error. hudson does not start the build as unsuccessful, it will always succeed.
Please let me know how I can cause a build to fail from the command line.
source
share