macOS application bundles are meant to be usable with both a GUI and CLI, if they are available.
The GUI, of course, is launched by opening the (ApplicationName).app bundle in Finder, or using the “open” command in a shell. CLIs are usually accessed by running the raw binary at (ApplicationName).app/Contents/(BinaryName, which might be different).
In the case of KoLmafia, that binary is JavaApplicationStub. I can launch it from the command line just fine, and I can see System.out and System.err normally. Unfortunately, unlike the JAR build, it just launches the GUI instead of accepting arguments.
I understand this is a very small issue, since users can just keep two copies of KoLmafia around, or just use a JAR for everything. But it may not be that hard to implement, and it would be very convenient. I’m not too familiar with Ant, so it might even be a matter of changing a setting somewhere.
The GUI, of course, is launched by opening the (ApplicationName).app bundle in Finder, or using the “open” command in a shell. CLIs are usually accessed by running the raw binary at (ApplicationName).app/Contents/(BinaryName, which might be different).
In the case of KoLmafia, that binary is JavaApplicationStub. I can launch it from the command line just fine, and I can see System.out and System.err normally. Unfortunately, unlike the JAR build, it just launches the GUI instead of accepting arguments.
I understand this is a very small issue, since users can just keep two copies of KoLmafia around, or just use a JAR for everything. But it may not be that hard to implement, and it would be very convenient. I’m not too familiar with Ant, so it might even be a matter of changing a setting somewhere.