新装Android(安卓)studio无法联网,总是报错Could not get resource 'https://jcenter.bintray.com
16lz
2021-01-25
最近电脑重装系统了,下载了AS,新建工程却总是没办法同步成功,后面把build.gradle改成如下,就可以成功了。
// Top-level build file where you can add configuration options common to all sub-projects/modules.buildscript { repositories { maven{ url'http://maven.aliyun.com/nexus/content/groups/public/' } jcenter { url 'http://maven.aliyun.com/nexus/content/repositories/jcenter' } maven{ url 'http://maven.aliyun.com/nexus/content/repositories/central/'} google() } dependencies { classpath 'com.android.tools.build:gradle:3.4.0' // NOTE: Do not place your application dependencies here; they belong // in the individual module build.gradle files }}allprojects { repositories { maven{ url'http://maven.aliyun.com/nexus/content/groups/public/' } jcenter { url 'http://maven.aliyun.com/nexus/content/repositories/jcenter' } maven{ url 'http://maven.aliyun.com/nexus/content/repositories/central/'} google() }}task clean(type: Delete) { delete rootProject.buildDir}
更多相关文章
- Android(安卓)Studio Rendering Problems
- Eclipse配置NDK编译Android工程
- Ant编译编译APK、打包打包JS
- Android(安卓)Studio 出现 error: cannot find symbol variable
- 搭建环境变量时遇到的三个错误
- 最新版本(OpenSSL1.0.1e)libssl.so, libcrypto.so for Android
- Unity3d调用Anroid(Android(安卓)Studio环境)方法
- Android(安卓)问题之找不到资源解决办法
- [置顶] Android更换皮肤