1

is there a way to update version of Gradle since the one used in AIDE is version 1.

Many functions are not applicable.

   // Top-level build file where you can add configuration options common to all sub-projects/modules.

    buildscript {
        repositories {
            jcenter()
        }
        dependencies {
            classpath 'com.android.tools.build:gradle:1.+'

            // NOTE: Do not place your application dependencies here; they belong
            // in the individual module build.gradle files
        }
    }

    allprojects {
        repositories {
            jcenter()
        }
    }
Paraskevas Ntsounos
  • 1,755
  • 2
  • 18
  • 34
Francis Nduba Numbi
  • 2,499
  • 1
  • 11
  • 22

2 Answers2

1

Update android build tool to the latest version:

classpath 'com.android.tools.build:gradle:3.1.3'

Also add google() in your buildscript. So update your existing code like below:

// Top-level build file where you can add configuration options common to all sub-projects/modules.

    buildscript {
        repositories {
            google()
            jcenter()
        }
        dependencies {
            classpath 'com.android.tools.build:gradle:3.1.3'

            // NOTE: Do not place your application dependencies here; they belong
            // in the individual module build.gradle files
        }
    }

    allprojects {
        repositories {
            google()
            jcenter()
        }
    }
Paraskevas Ntsounos
  • 1,755
  • 2
  • 18
  • 34
0

Try to delete the line:

classpath 'com.android.tools.build:gradle:1.+' 

if that doesnt't help, copy this line to build.gradle:

classpath 'com.android.tools.build:gradle:3.0.1'