android / user-interface-samples

Multiple samples showing the best practices in the user interface on Android.
Apache License 2.0
4.38k stars 1.64k forks source link

can‘t build projection successfully #87

Open millerJK opened 7 years ago

millerJK commented 7 years ago

Hi, I got a problem which application can not be build . I have download Android Studio 3.0 and Android O sdk . and add code
maven { url "https://maven.google.com" }

in build.gradle ,but I just can't also build application successfully . here is my code in build.gradle ,is there something error ?

android { compileSdkVersion 'android-O' buildToolsVersion '26.0.0-rc2' defaultConfig { applicationId "com.example.javris.myapplication" minSdkVersion 'O' targetSdkVersion 'O' versionCode 1 versionName "1.0" } buildTypes { release { minifyEnabled false proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' } }

}

allprojects { repositories { jcenter() maven { url "https://maven.google.com" } } }

dependencies { compile fileTree(dir: 'libs', include: ['*.jar']) compile 'com.android.support:appcompat-v7:26.+' compile "com.android.support:support-emoji:26.0.0-beta1" compile 'com.android.support.constraint:constraint-layout:1.0.2' }

Error information : Error:Failed to resolve: Could not resolve com.android.support:support-emoji:26.0.0-beta1.

I found when I try to rely on other library such as : compile "com.android.support:support-dynamic-animation:26.0.0-beta1" ,it will be error either .

I think I just can't connect to 'https://maven.google.com' . I got 404 when visited by website . by the way I have to use VPN visite google website.

Is there any solution? Looking forward to your reply,thanks !

futabooo commented 7 years ago

@millerJK yourproject/gradle/wrapper/gradle-wrapper.properties to change bellow

distributionUrl=https\://services.gradle.org/distributions/gradle-4.0-milestone-1-all.zip