1、跳过测试
gradlew build -x test
2、编译失败,提示信息为
Failed to create MD5 hash for file 'F:\code\spring-framework\build\distributions\spring-framework-5.0.5.BUILD-SNAPSHOT-schema.zip'
出现该问题,是因为windows环境下的路径寻找问题。
解决方法:修改项目中gradle配置的Zip路径
如果是master版本,则修改Spring-framework\gradle\docs.gradle文件
如果是4.3.x版本,则修改Spring-framework\build.gradle文件
查找 task schemaZip(type: Zip) 模块
it.path.endsWith("META-INF/spring.schemas")
修改为
it.path.endsWith("META-INF\\spring.schemas")
it.path.endsWith(schemas.get(key))
修改为
it.path.endsWith(schemas.get(key).replaceAll('\\/','\\\\'))