You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am working on a CLI Application based on Quarkus and Picocli using JLINE3.
One command forks another application / shell script which uses "trap" to react on system signals.
Once the application is forked i can use my CLI Application normally and everything works as expected, but when i use 'ctrl-c' to e.g. abort the current line the signal is "trapped" by my forked application and it terminates.
I tried implementing signal handling for the terminal as documented here https://github.com/jline/jline3/wiki/Terminals#signal-support or even directly implementing sun.misc.SignalHandler. But none of my ideas worked - nothing ever hit my signal handler.
I also tried to override the keybinding ctrl-c to a custom widget - but that also failed to give the result i want.
The forked script terminates and i get a UserInterruptException from the LineReader - afterwards.
I am working on a CLI Application based on Quarkus and Picocli using JLINE3.
One command forks another application / shell script which uses "trap" to react on system signals.
Once the application is forked i can use my CLI Application normally and everything works as expected, but when i use 'ctrl-c' to e.g. abort the current line the signal is "trapped" by my forked application and it terminates.
I tried implementing signal handling for the terminal as documented here https://github.com/jline/jline3/wiki/Terminals#signal-support or even directly implementing sun.misc.SignalHandler. But none of my ideas worked - nothing ever hit my signal handler.
I also tried to override the keybinding ctrl-c to a custom widget - but that also failed to give the result i want.
The forked script terminates and i get a UserInterruptException from the LineReader - afterwards.
I started of with this demo https://github.com/remkop/picocli/tree/main/picocli-shell-jline3
I was pointed in the direction of jline3 by @remkop to seek for help here. :)
I raised the issue here remkop/picocli#2213 in the first place.
The text was updated successfully, but these errors were encountered: