Hi,
I am trying to run plantuml to generate diagrams in my nodejs application. My script looks like this:
const cmd = `java -jar "${JAR_PATH}" -failfast2 -pipe > "${imageOutputPath}"`;
const childProcess = exec(cmd);
childProcess.stdin.write(
content,
(e) => {
if (e) {
logger.debug(e);
}
childProcess.stdin.end();
},
);
Because I don't have Graphviz installed, I am expecting the execution to fail fast and not generate any diagram, but it still generates a diagram with the error that Graphviz is not found. I also tried `-noerror` and it does not seem to work as expected(diagrams are still generated). This is tested against v1.2020.17 and the latest release (I know the latest version includes Graphviz by default but I found it to be flaky, i.e. sometimes it still generates error diagrams, which I don't want).
I am not sure what went wrong and would like to ask if there is a right way to skip generating diagrams when there is an error.
Thank you in advance!