編譯Spring源碼

1.下載源碼

git clone --branch v5.2.8.RELEASE https://gitee.com/Z201/spring-framework.git

2.修改配置文件

  1. 修改settings.gradle文件
repositories {
 gradlePluginPortal()
 maven { url 'https://maven.aliyun.com/repository/public' }
 maven { url 'https://repo.spring.io/plugins-release' }
}
  1. 修改build.gradle文件
    注釋 // id "io.spring.gradle-enterprise-conventions" version "0.0.2" 編譯不通過
repositories {
            maven { url 'https://maven.aliyun.com/nexus/content/groups/public/' }
            maven { url 'https://maven.aliyun.com/nexus/content/repositories/jcenter'}
            mavenCentral()
            maven { url "https://repo.spring.io/libs-spring-framework-build" }
        }
  1. 修改gradle.properties文件
version=5.2.8.RELEASE
org.gradle.jvmargs=-Xmx2048M
org.gradle.caching=true
org.gradle.parallel=true
org.gradle.configureondemand=true
org.gradle.daemon=true

3. 編譯

找到spring源碼目錄cmd運(yùn)行 gradlew :spring-oxm:compileTestJava


spring.png

idea安裝Kotlin

image.png

spring源碼導(dǎo)入idea

image.png

找到spring源碼目錄


image.png
image.png
?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請聯(lián)系作者
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時(shí)請結(jié)合常識與多方信息審慎甄別。
平臺聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點(diǎn),簡書系信息發(fā)布平臺,僅提供信息存儲服務(wù)。

相關(guān)閱讀更多精彩內(nèi)容

友情鏈接更多精彩內(nèi)容