Menu

#22 console

v1.0 (example)
closed
nobody
None
5
2014-03-16
2014-01-27
No

When running from console we'd expect a process exit code of zero when all is okay and something non-zero (for stupid batch files preferably a positive number like 1) when the chm file is not generated.
If you want to implement this and you are are willing to do some refactoring I'd recommend that you only catch exceptions at the highest level so that you can decide what to do about the error from where the call was placed. Otherwise without refactoring you can place global variable that stores whether an error has happened and set that when an exception was caught (but i think this is a hack).

To test this, call the app from console like this:

ChmProcessor.exe /g /y /q x.WHC && echo ok

If you have the chm file in the reader it cannot be overwritten so you should not see ok being printed. If all goes okay you should see ok printed.

Discussion

  • Antonio Fco. Bennasar Obrador

    Ill check the log generation. Something like: If there is error messages, it will return 2, if there is warnings 1, and 0 otherwise.

     
  • Antonio Fco. Bennasar Obrador

    Done. It will be in 1.7.1. Codes are 0= ok, 1= warnings, 2= errors

     
  • Antonio Fco. Bennasar Obrador

    • status: open --> closed
     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.