Richard504 2022-08-17 18:15 采纳率: 0%
浏览 95
已结题

Plugin xx was not found in xx

问题遇到的现象和发生背景

刚学习gradle,尝试使用gradle classes对源文件进行编译,报错
settings.gradle和build.gradle已经添加阿里云仓库

问题相关代码,请勿粘贴截图
  • What went wrong:
    Plugin [id: 'org.springframework.boot', version: '2.3.5.RELEASE‘] was not found in any of the following sources:
  • Gradle Core Plugins (plugin is not in 'org.gradle' namespace)
  • Plugin Repositories (could not resolve plugin artifact 'org.springframework.boot:org.springframework.boot.gradle.plugin:2.3.5.RELEASE')
    Searched in the following repositories:
    Gradle Central Plugin Repository
    maven(https://maven.aliyun.com/repository/gradle-plugin)
我的解答思路和尝试过的方法

build.gradle文件内容
plugins {
id 'org.springframework.boot' version '2.3.5.RELEASE'
id 'io.spring.dependency-management' version '1.0.12.RELEASE'
id 'java'
}

group = 'com.atguigu'
version = '0.0.1-SNAPSHOT'
sourceCompatibility = '1.8'

repositories {

mavenLocal()
maven {
allowInsecureProtocol = true
name "Alibaba" ;
url "https://maven.aliyun.com/repository/public" }
maven {
allowInsecureProtocol = true
name "Bstek" ;
url "https://nexus.bsdn.org/content/groups/public/" }
mavenCentral()
}

dependencies {
implementation 'org.springframework.boot:spring-boot-starter'
testImplementation 'org.springframework.boot:spring-boot-starter-test'
}

tasks.named('test') {
useJUnitPlatform()
}

setting.gradle文件内容
pluginManagement {
repositories {
gradlePluginPortal()
maven {
allowInsecureProtocol = true
url "https://maven.aliyun.com/repository/gradle-plugin" }
}
}
rootProject.name = 'demo'

  • 写回答

1条回答 默认 最新

  • Richard504 2022-08-17 18:34
    关注

    img


    是不是因为版本号错误?

    评论

报告相同问题?

问题事件

  • 系统已结题 8月25日
  • 创建了问题 8月17日

悬赏问题

  • ¥15 完成下列问题完成下列问题
  • ¥15 C#算法问题, 不知道怎么处理这个数据的转换
  • ¥15 YoloV5 第三方库的版本对照问题
  • ¥15 请完成下列相关问题!
  • ¥15 drone 推送镜像时候 purge: true 推送完毕后没有删除对应的镜像,手动拷贝到服务器执行结果正确在样才能让指令自动执行成功删除对应镜像,如何解决?
  • ¥15 求daily translation(DT)偏差订正方法的代码
  • ¥15 js调用html页面需要隐藏某个按钮
  • ¥15 ads仿真结果在圆图上是怎么读数的
  • ¥20 Cotex M3的调试和程序执行方式是什么样的?
  • ¥20 java项目连接sqlserver时报ssl相关错误