贝隆

  博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理

本地目录:

gradle-wrapper.properties

 

distributionUrl=file\:///D:/\.gradle/gradle-7.3-all.zip
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStorePath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME

 

https://blog.csdn.net/Stone__Fly/article/details/108222960

 

repositories {
//阿里云仓库全家桶
maven{ url 'https://maven.aliyun.com/repository/central'}
maven{ url 'https://maven.aliyun.com/repository/public' }
maven{ url 'https://maven.aliyun.com/repository/google'}
maven{ url 'https://maven.aliyun.com/repository/gradle-plugin'}
maven{ url 'https://maven.aliyun.com/repository/spring'}
maven{ url 'https://maven.aliyun.com/repository/spring-plugin'}
maven{ url 'https://maven.aliyun.com/mvn/guide'}
maven{ url 'https://maven.aliyun.com/repository/apache-snapshots'}
}

https://blog.csdn.net/Stone__Fly/article/details/108222960

在Gradle安装目录下的 init.d 文件夹下,新建一个 init.gradle 文件,里面填写以下配置。

allprojects {
repositories {
maven { url 'file:///C:/Java/maven_repository'}
mavenLocal()
maven { name "Alibaba" ; url "https://maven.aliyun.com/repository/public" }
maven { name "Bstek" ; url "http://nexus.bsdn.org/content/groups/public/" }
mavenCentral()
}
buildscript {
repositories {
maven { name "Alibaba" ; url 'https://maven.aliyun.com/repository/public' }
maven { name "Bstek" ; url 'http://nexus.bsdn.org/content/groups/public/' }
maven { name "M2" ; url 'https://plugins.gradle.org/m2/' }
}
}
}

等待下载完成之后,进入目录执行

gradlew :spring-oxm:compileTestJava
posted on 2022-11-02 22:33  贝隆  阅读(57)  评论(0)    收藏  举报