aglio
aglio copied to clipboard
CLI: exit process with correct error code
I've seen that there is already a resolved ticket (#38) about that issue. But it seems that when I have warnings during the generation, the return code is 0.
Here is the launched command:
aglio --theme flatly --theme-template index.jade --theme-full-width true -i book.apib -o book.html
Am I missing something?
If I redirect stderr to a file, I get all errors and warnings in that file. That means that there is an unconsitency between the output and the exit code. As a workaround, I output every error and warning messages to a file and test the file.
A warning message isn't an error, though? So it shouldn't affect the exit code? A non-zero exit code would be considered an error.
I agree that a warning is not an error, but there should be something to differentiate a process that works flawlessly and one with warnings. Maybe a switch to convert warnings to errors.