cbdeveloper
cbdeveloper

Reputation: 31345

Run .sh shell script file from VSCode PowerShell CLI?

What I've tried:

These were the results:

The term 'bash' is not recognized...

The term 'sh' is not recognized...

enter image description here

Upvotes: 0

Views: 6026

Answers (2)

mr penguin
mr penguin

Reputation: 1

i read you're suppose to use chmod +x scriptname.sh before using the bash command

Upvotes: -1

Porky
Porky

Reputation: 988

This may sound daft, but if you are in a Powershell shell how will that shell know where to find the bash or sh interpreter? Is it already defined in the environment?

In my opinion you're going to have to tell the Powershell terminal where it should find the bash/sh interpreter, i.e. call bash it with the full pathname

Upvotes: 1

Related Questions