如何使用idea编译spring-framework源码

下载spring-framework源码,建议使用git clone的方式,便于切换分支
直接使用github下载速度很慢,可以使用镜像地址下载

https://hub.fastgit.org/spring-projects/spring-framework
访问上面的地址,复制git地址
git clone https://hub.fastgit.org/spring-projects/spring-framework.git

PS:一定不要自己安装gradle,版本不一致的问题会搞死人

代码卸载完成

先修改build.gradle文件,

不要直接点击gradlew.bat,使用cmd窗口运行,可以查看日志

直到出现build successful,期间如果有下载异常,多半是网络问题,无脑重试即可,直到成功

在导入idea前,先执行gradlew :spring-oxm:compileTestJava, 这个步骤会下载一些依赖,如下载失败同样进行重试,直至成功

成功后导入idea,

4.0.0 org.springframework spring-framework-bom 5.3.39 pom Spring Framework (Bill of Materials) Spring Framework (Bill of Materials) https://github.com/spring-projects/spring-framework Spring IO https://spring.io/projects/spring-framework Apache License, Version 2.0 https://www.apache.org/licenses/LICENSE-2.0 repo jhoeller Juergen Hoeller jhoeller@pivotal.io scm:git:git://github.com/spring-projects/spring-framework scm:git:git://github.com/spring-projects/spring-framework https://github.com/spring-projects/spring-framework GitHub https://github.com/spring-projects/spring-framework/issues org.springframework spring-aop 5.3.39 org.springframework spring-aspects 5.3.39 org.springframework spring-beans 5.3.39 org.springframework spring-context 5.3.39 org.springframework spring-context-indexer 5.3.39 org.springframework spring-context-support 5.3.39 org.springframework spring-core 5.3.39 org.springframework spring-expression 5.3.39 org.springframework spring-instrument 5.3.39 org.springframework spring-jcl 5.3.39 org.springframework spring-jdbc 5.3.39 org.springframework spring-jms 5.3.39 org.springframework spring-messaging 5.3.39 org.springframework spring-orm 5.3.39 org.springframework spring-oxm 5.3.39 org.springframework spring-r2dbc 5.3.39 org.springframework spring-test 5.3.39 org.springframework spring-tx 5.3.39 org.springframework spring-web 5.3.39 org.springframework spring-webflux 5.3.39 org.springframework spring-webmvc 5.3.39 org.springframework spring-websocket 5.3.39
最新发布
11-11
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值