Gradle Script unable to compile groovy file


(Reddy Madhu Sudhan) #1

After adding dependency also still build is failing. Please find the below error

unable to resolve class
unable to resolve class

build.gradle :

buildscript {
repositories {
maven {
url ‘

dependencies {
   classpath  'org.apache.commons:commons-io:1.3.2'
   classpath files('C:\\Users\\xxx\\Downloads\\docker-client-master\\client\\build\\libs\\client.jar')
   classpath 'com.squareup.okhttp3:okhttp:3.6.0'
   classpath 'de.gesellix:docker-filesocket:2017-02-26T08-19-34'
   classpath 'org.codehaus.groovy.modules.http-builder:http-builder:0.5.2'


(James Justinic) #2

You’re adding these dependencies shown to your buildscript classpath, which would be correct only if you’re intending to use these libraries in the buildscript itself. If you’re trying to use these dependencies in groovy code that your buildscript is compiling, you need a repositories and dependencies block outside of the buildscript block.