zoukankan      html  css  js  c++  java
  • 终于从Gradle 坑中爬出来了。Running gradle task 长时间被卡问题解决代码

    为了见到这个Demo界面,害得我删了装,装了删,也最终下决心将系统从Win7 换到了Win10.

    Baidu了不下100次。终于功夫不负有心人,模拟器终于跑出来了;

    环境情况;

    操作系统:Win10 X64

    Android studio 4.1.2

    Flutter : 1.27.0-4.0.pre

    Git

    buildscript {
        ext.kotlin_version = '1.3.50'
        repositories {
            maven{ url 'http://maven.aliyun.com/nexus/content/groups/public/'}
            maven{ url 'http://maven.aliyun.com/nexus/content/repositories/jcenter'}
            maven{ url 'http://maven.aliyun.com/nexus/content/repositories/google' }
            //google()
         //jcenter这个函数不知是不是重点,最终靠他解决了问题.就是加上花括号,写上url "http://jcenter.bintray.com/"
    jcenter(){
    url
    "http://jcenter.bintray.com/"
    } } dependencies { classpath 'com.android.tools.build:gradle:3.5.0' classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" } } allprojects { repositories { maven{ url 'http://maven.aliyun.com/nexus/content/groups/public/'} maven{ url 'http://maven.aliyun.com/nexus/content/repositories/jcenter'} maven{ url 'http://maven.aliyun.com/nexus/content/repositories/google' } //google() //jcenter() } } rootProject.buildDir = '../build' subprojects { project.buildDir = "${rootProject.buildDir}/${project.name}" } subprojects { project.evaluationDependsOn(':app') } task clean(type: Delete) { delete rootProject.buildDir }

     其实问题就是不能下载gradle ,但试了N种方法,就是老卡在Running gradle task.

    于是就换版本,改build.gradle文件的配置 ;

    活到老,学到老。
  • 相关阅读:
    关于ACID,BASE和CAP定理的探究
    2020年10月3日——武汉,成都,南京房价揭秘
    程序员如何选择自己的保险
    Yarn系列(一)——Yarn整体介绍
    利用媒体查询实现响应式布局
    移动端web布局:适配
    scss在编辑器中保存自动编译css插件及安装
    移动端web布局:像素与成像的基本原理
    微信小程序:路由
    自定义vue指令
  • 原文地址:https://www.cnblogs.com/lrzy/p/14425900.html
Copyright © 2011-2022 走看看