Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Travis run-check permission denied error solution?

I spent a few hours on searching how to resolve this error but can't find any solution to do so. My gradle build is successful, and this is the first time I am getting a permission denied for my run-checks.sh.

Even if I revert to old code that passes the travis checks, it gives me the same permission denied as well.

I was wondering is it affected by the idea/workspace.xml file?

Any idea how I could go about this?

0.00s$ ./config/travis/run-checks.sh && travis_retry ./gradlew clean 
checkstyleMain checkstyleTest headless allTests coverage coveralls asciidoctor 
copyDummySearchPage
/home/travis/.travis/job_stages: line 104: ./config/travis/run-checks.sh: 
Permission denied
like image 911
GCDX Avatar asked Nov 08 '22 01:11

GCDX


1 Answers

Travis is trying to run a file ./config/travis/run-checks.sh, but it doesn't have permissions to execute that file.

You'll need to give it permissions depending on where run-checks.sh lives. If this is something from your repo, you can give it permission to execute with:

git update-index --add --chmod=+x ./config/travis/run-checks.sh git commit -m "Added permissions for run-checks.sh" git push

If it's a script that's only available and found in travis' own environment, then you'll need travis to execute giving the permission.

before_script: - chmod +x build.sh

Related: https://stackoverflow.com/a/42714604/245268

like image 71
Jonn Avatar answered Nov 14 '22 23:11

Jonn