davsclaus commented on code in PR #28113:
URL: https://github.com/apache/camel/pull/28113#discussion_r4315409234
##########
dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/common/RuntimeUtil.java:
##########
@@ -117,12 +130,14 @@ public static void configureLog(
} else if (json) {
location = "log4j2-json.properties";
} else if (color) {
- location = "log4j2.properties";
+ location = COLOR_CONFIG;
} else {
location = "log4j2-no-color.properties";
}
synchronized (RuntimeUtil.class) {
+ // log4j resolves the name of a log file when it loads the
configuration
+ System.setProperty(LOG_DIR,
CommandLineHelper.getCamelDir().toString());
Review Comment:
`camel.jbang.logDir` is not an option: the CLI sets it so that log4j writes
`<pid>.log` in the Camel directory of the CLI, where `camel log` and the AI
tools read the log of a pid. Another directory would hide the log from them. It
is set each time because that directory can change, such as in the tests.
ec03478e84e9 adds a comment that says so.
_Claude Code on behalf of Claus Ibsen_
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]