idea下的Spring5.x源碼編譯、閱讀


一.下載spring源碼

git clone git@github.com:spring-projects/spring-framework.git

二.預編譯

參考import-into-idea.md文件

1. Precompile `spring-oxm` with `./gradlew :spring-oxm:compileTestJava`
2. Import into IntelliJ (File -> New -> Project from Existing Sources -> Navigate to directory -> Select build.gradle)
3. When prompted exclude the `spring-aspects` module (or after the import via File-> Project Structure -> Modules)
4. Code away

這里翻譯一下

1.進入進入spring-framework目錄,執行命令  ./gradlew :spring-oxm:compileTestJava

2.啟動idea,File -> New -> Project from Existing Sources -> Navigate to directory -> Select build.gradle

3.等待編譯完成

三.編寫測試demo

四.spring每個模塊都有test,大家可以進去跟蹤調試。


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM