The shell doc for bash says " The default shell on non-Windows platforms with a fallback to sh
. When specifying a bash shell on Windows, the bash shell included with Git for Windows is used."
https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsshell
So I am assuming the shell: bash will invoke a git-bash on windows. I have C:\ Program Files\Git\Bin in the environment PATH variable. Despite this if I specify shell: bash in the task for any command it shows error “ERROR: bash: command not found”
- name: testing git-bash with shell=bash
shell: bash
run: |
echo "This is exceution of command hostname with specifying bash shell"
hostname
Error:
So, how to make git-bash working as bash shell in windows runner?