I can't debug shell scripts
I have the plugin Shell Scripts installed which supposedly gives me the ability to debug a shell script. I tried this recently and couldn't get it to work. Under Run/Debug configurations I created a new Shell Script configuration and entered the path to my script. I also entered the path to my Bash interpreter (Git Bash), at C:\Program Files\Git\bin\bash.exe. However, when I tried to debug the script I got the error message "Debug: there are no runners for Shell Script". I don't know what this means. Also, I noticed that I can't set breakpoints in my Bash script.
Please sign in to leave a comment.
Debugging is not yet supported by the Shell Script plugin at the moment.
On Windows, however, you can't even run a script because the interpreter won't be able to understand Windows-like paths.
If you feel like we should have both supported, please submit them to the IDEA's issue tracker using this link.
I have a bundle application license for a number of apps (2020.x), but so far I wasn't able to find one that supports bash scripts, even if it's only for syntax highlight. Does JetBrains have an application that supports Bash Script?
As you know the Bash Support plugin was retired and the new version is paid from now on. So, if I need support for Bash Script (which I need with JavaScript, Python, C++) do I have to pay a monthly subscription for an external plugin?
My current solution is to use another application (usually Atom) to see the syntax highlight on bash scripts. Being completely sincere, it sounds weird that JetBrains doesn't have support for that because virtually every developer does at least a minimum of shell script coding, independent of the main language used.
Am I missing anything?
Please, help me with some clarification and guidance.
Thanks.
Almircampos, I migrated all my Bash Support plugin run configurations to the bundled "Shell Script" plugin's one https://plugins.jetbrains.com/plugin/13122-shell-script (only drawback being the lack of configurable environment variables which are allegedly arriving with 2020.3: https://youtrack.jetbrains.com/issue/IDEA-245850). This supports also Shell Check.
Let's examine some possible answers below:
Unfortunately, none of them is true, in my case. I just made some wrong assumptions and acted stupidly before checking them (duh!).
When the support asked me for a screenshot of the problem, the truth came out. Sorry about that...
Well even if it does not have the debugger the Shell Script plugin gives REALLY good hints. I was surprised. And it provides with really good explanations on such or such issue. Really really convenient! And for those who looks for debugging functionality - please read this article completely and I believe it will provide you with good
debugging techniquesthat make it simpler to actually analyze the issue it will not substitute actuall step by step debugging execution (but probably you will realize that you do not need it, after you read that article). Read here: https://linuxconfig.org/how-to-debug-bash-scriptsWish you All the best!