Debug shell script in IntelliJ 9
Is it possible to debug a shell script in In开发者_Python百科telliJ IDEA 9.0.3. I hava a shell script that calls a java program. I would like to set a breakpoint in this java program and debug through it. I hava a Bash plugin for IntelliJ and have set the breakpoint in the program but it doesn't stop at the breakpoint. Thanks, Tom
You can use Remote Debug to debug the Java program which you run from the shell script. IDEA will suggest you the list of JVM options, add them inside the shell script where you call Java VM. If suspend is enabled, the app will wait for IDEA debugger connection so that you can connect and start the debug session and stop on the breakpoints.
It's not possible to debug the shell script itself in IDEA.
Just run the Java program in IntelliJ. What do you need the bash script for? Let IntelliJ run your Java program and let it provide the environment and inputs that bash is giving it.
If you do that your breakpoints will work just fine.
精彩评论