Error:Could not install Gradle distribution from 'https://services.gradle.org/distributions/gradle-2
来源:互联网 发布:数据透视表行合计 编辑:程序博客网 时间:2024/05/12 06:52
AS报错之 Error:Could not install Gradle distribution from ‘https:/ /services.gradle.org/distributions/gradle-2.2.2-all.zip’.
解决方案
这个错误一般是导入了网上的GitHub项目 或者别人的项目引起的。
以下是我个人的解决方法
字面意思也就是说 现在安装不了 也找不到这个版本的Gradle!
先进到Gradle的设置页面 Settings-Build, Execution, Deployment-Gradle
选择用本地的Gradle插件 并输入路径D:/ASinstall/gradle/gradle-2.14.1
然后 出现了这个报错
Error:(2, 0) No service of type Factory available in ProjectScopeServices.
这个错误点击open file 会跳转到apply plugin: ‘com.github.dcendents.android-maven’这行。
这个你需要更新maven-plugin的依赖 将这两行代码添加到dependencies{} 依赖 标签内 classpath 'com.github.dcendents:android-maven-gradle-plugin:1.5'
classpath 'com.android.tools.build:gradle:2.2.2'
这些依赖项 是为了将代码什么的上传至那个公共的jCenter上面
还要注意 项目-gradle-gradle-wrapper-wrapper.properties下的 distributionUrl= 是对的
最后 File-Invalidate Caches/Restars… 项目
、
拓展:
啥是Bintray?啥是jCenter?
首先说jCenter,是一个代码库,相当于一个公共的存储控件,简单的来讲就是你把你写好的aar文件及一些文档描述文件之类的东西打包上传到jCenter服务器上,其他人就可以通过jCenter服务器下载到你上传的包了。
那Bintray又是啥?Bintray是jCenter的提供商,他支持上传lib到多个平台,jCenter只是众多平台中的一个,形象的说jCenter是位于某地的仓库,Bintray是送货的卡车,你写的库就是货了
- Error:Could not install Gradle distribution from 'https://services.gradle.org/distributions/gradle-2
- Error:Could not install Gradle distribution from 'https://services.gradle.org/distributions/gradle-2
- Error:Could not install Gradle distribution from 'https://services.gradle.org/distributions/gradle
- 报错 Error:Could not install Gradle distribution from 'https://services.gradle.org/distributions/gradl
- Could not install Gradle distribution from 'https://services.gradle.org/distributions/gradle-3.3-all
- Could not install Gradle distribution from 'http://services.gradle.org/distributions/gradle-xx-all
- Error:Gradle distribution 'https://services.gradle.org/distributions/gradle-3.3-all.zi
- org.gradle.tooling.GradleConnectionException: Could not install Gradle distribution from
- Distribution download cancelled. Using distribution from 'https://services.gradle.org/distributions/
- [Gradle]org.gradle.tooling.GradleConnectionException: Could not install Gradle distribution from 'ht
- [Gradle]org.gradle.tooling.GradleConnectionException: Could not install Gradle distribution from 'h
- Could not install Gradle distribution
- https://services.gradle.org/distributions/gradle-2.14.1-all.zip
- Android Studio bug:Error:Could not run build action using Gradle distribution 'https://services.grad
- Error:Cause: https://downloads.gradle.org/distributions/gradle
- 离线配置gradle时,打开Android Studio会报错 “Error:Gradle distribution 'https://services.gradle.org/distribution
- Android Studio org.gradle.tooling.GradleConnectionException: Could not install Gradle distribution f
- adnroid studio卡在Gradle:Download https://services.gradle.org/distributions/gradle-3.2-all.zip解决办法
- PHP语法
- 网易2017年秋招第三题
- jQuery学习教程二十: jQuery 遍历
- 找假币
- debug.keystore改成和发布的key的sha1签名一样
- Error:Could not install Gradle distribution from 'https://services.gradle.org/distributions/gradle-2
- 正则表达式常见例子
- 关于使用php连接sql server的方法
- 西瓜书第五章 神经网络
- py 流程控制语法
- VIM 使用技巧汇总——————持续更新中
- 伍蒙的C++作业3实验
- GB2312、GBK与UTF-8的区别
- Unity3D:简单太阳系的制作