Closed cescoffier closed 2 weeks ago
/cc @ebullient (cli), @maxandersen (cli)
@cescoffier running with quarkus cli how? as a quarkus plugin or ?
Like this:
generate-unsigned-certificate:
rm -Rf .certs
quarkus tls generate-certificate --name=local --password=secret --self-signed
The workaround is to append || true
to the quarkus
command, but it should not be required.
okey, reproduced with simple code like this:
///usr/bin/env jbang "$0" "$@" ; exit $?
import static java.lang.System.*;
public class qhello {
public static void main(String... args) {
int exitCode = 0;
if (args.length > 0) {
try {
exitCode = Integer.parseInt(args[0]);
} catch (NumberFormatException e) {
// If parsing fails, exitCode remains 0
}
}
out.println("Exit with: " + exitCode);
System.exit(exitCode);
}
}
when running this with jbang the exit code is bubbling up correctly but when running with quarkus cli it is for some reason always 1.
jbang qhello.java 4r2
[jbang] Building jar for qhello.java...
Exit with: 0
❯ jbang qhello.java 42; echo $?
Exit with: 42
42
❯ quarkus qhello 42; echo $?
Exit with: 42
1
Describe the bug
I have a command with the following main method:
The
exitCode
is0
.However, when running with the
quarkus
CLI, I get a1
status, breaking all the scripts:Expected behavior
No response
Actual behavior
No response
How to Reproduce?
No response
Output of
uname -a
orver
No response
Output of
java -version
No response
Quarkus version or git rev
No response
Build tool (ie. output of
mvnw --version
orgradlew --version
)No response
Additional information
No response