How to import cwac camera library

1.2k Views Asked by At

I am trying to import this project in my android studio version 2.1.2

But I am getting below error couldn't solve it .

Error :

Error:(12, 13) Failed to resolve: com.commonsware.cwac:camera:0.6.12 Show in File
Show in Project Structure dialog

Any help would be appreciated Thanks.

2

There are 2 best solutions below

1
chandrakant On

please use this way.

repositories {
    maven {
        url "https://repo.commonsware.com.s3.amazonaws.com"
    }
}

dependencies {
    compile 'com.commonsware.cwac:camera:0.6.+'
}
0
Peter Chaula On

You must also include maven central repo like so : mavenCentral() so that you won't break your exisiting dependencies

repositories {
    maven {
        url "https://repo.commonsware.com.s3.amazonaws.com"
    }

    mavenCentral()
}

dependencies {
    compile 'com.commonsware.cwac:camera:0.6.+'
}