Execute shell script in Gradle

use

commandLine 'sh', './myScript.sh'

your script itself is not a program itself, that’s why you have to declare ‘sh’ as the program and the path to your script as an argument.

Leave a Comment