I was working in androidstudio today and my builds started failing. To my surprise, I had lost my internet connection and could no longer build my code.

build.gradle file contains the following:

```
buildscript {
    repositories {
        mavenCentral()
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:0.6.3'
    }
    tasks.withType(Compile) {
        options.encoding = "UTF-8"
    }
}
apply plugin: 'android-library'

dependencies {
    compile files('libs/android-support-v4.jar')
}
...

```

So ... how do I reconfigure my development environment, change my build.gradle and do whatever else is necessary to allow android development offline.

**Note:** Question edited to remove mavenLocal() from repositories, since it was added trying to solve this problem myself