Port the build to Gradle
Closes gh-19609 Closes gh-19608
This commit is contained in:
@@ -4,7 +4,7 @@ class Springboot < Formula
|
||||
homepage 'https://spring.io/projects/spring-boot'
|
||||
url 'https://repo.spring.io/${repo}/org/springframework/boot/spring-boot-cli/${project.version}/spring-boot-cli-${project.version}-bin.tar.gz'
|
||||
version '${project.version}'
|
||||
sha256 '${checksum}'
|
||||
sha256 '${hash}'
|
||||
head 'https://github.com/spring-projects/spring-boot.git'
|
||||
|
||||
if build.head?
|
||||
|
||||
@@ -42,8 +42,8 @@ public class SpringBootDependenciesDependencyManagement extends MavenModelDepend
|
||||
modelProcessor.setModelReader(new DefaultModelReader());
|
||||
|
||||
try {
|
||||
return modelProcessor.read(
|
||||
SpringBootDependenciesDependencyManagement.class.getResourceAsStream("effective-pom.xml"), null);
|
||||
return modelProcessor.read(SpringBootDependenciesDependencyManagement.class
|
||||
.getResourceAsStream("spring-boot-dependencies-effective-bom.xml"), null);
|
||||
}
|
||||
catch (IOException ex) {
|
||||
throw new IllegalStateException("Failed to build model from effective pom", ex);
|
||||
|
||||
@@ -17,7 +17,6 @@
|
||||
package org.springframework.boot.cli.compiler.maven;
|
||||
|
||||
import java.io.File;
|
||||
import java.lang.reflect.Field;
|
||||
|
||||
import org.apache.maven.settings.Settings;
|
||||
import org.apache.maven.settings.building.DefaultSettingsBuilderFactory;
|
||||
@@ -83,21 +82,7 @@ public class MavenSettingsReader {
|
||||
}
|
||||
|
||||
private SettingsDecrypter createSettingsDecrypter() {
|
||||
SettingsDecrypter settingsDecrypter = new DefaultSettingsDecrypter();
|
||||
setField(DefaultSettingsDecrypter.class, "securityDispatcher", settingsDecrypter,
|
||||
new SpringBootSecDispatcher());
|
||||
return settingsDecrypter;
|
||||
}
|
||||
|
||||
private void setField(Class<?> sourceClass, String fieldName, Object target, Object value) {
|
||||
try {
|
||||
Field field = sourceClass.getDeclaredField(fieldName);
|
||||
field.setAccessible(true);
|
||||
field.set(target, value);
|
||||
}
|
||||
catch (Exception ex) {
|
||||
throw new IllegalStateException("Failed to set field '" + fieldName + "' on '" + target + "'", ex);
|
||||
}
|
||||
return new DefaultSettingsDecrypter(new SpringBootSecDispatcher());
|
||||
}
|
||||
|
||||
private class SpringBootSecDispatcher extends DefaultSecDispatcher {
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
{
|
||||
"homepage": "https://projects.spring.io/spring-boot/",
|
||||
"version": "${scoop-version}",
|
||||
"version": "${scoopVersion}",
|
||||
"license": "Apache 2.0",
|
||||
"hash": "${hash}",
|
||||
"url": "https://repo.spring.io/${repo}/org/springframework/boot/spring-boot-cli/${project.version}/spring-boot-cli-${project.version}-bin.zip",
|
||||
"extract_dir": "spring-${project.version}",
|
||||
"bin": "bin\\spring.bat",
|
||||
"bin": "bin\\\\spring.bat",
|
||||
"suggest": {
|
||||
"JDK": [
|
||||
"java/oraclejdk",
|
||||
@@ -14,13 +14,13 @@
|
||||
},
|
||||
"checkver": {
|
||||
"github": "https://github.com/spring-projects/spring-boot",
|
||||
"re": "/releases/tag/(?:v)?(2[\\d.]+)\\.RELEASE"
|
||||
"re": "/releases/tag/(?:v)?(2[\\d.]+)\\\\.RELEASE"
|
||||
},
|
||||
"autoupdate": {
|
||||
"url": "https://repo.spring.io/release/org/springframework/boot/spring-boot-cli/$version.RELEASE/spring-boot-cli-$version.RELEASE-bin.zip",
|
||||
"extract_dir": "spring-$version.RELEASE",
|
||||
"url": "https://repo.spring.io/release/org/springframework/boot/spring-boot-cli/\$version.RELEASE/spring-boot-cli-\$version.RELEASE-bin.zip",
|
||||
"extract_dir": "spring-\$version.RELEASE",
|
||||
"hash": {
|
||||
"url": "$url.sha256"
|
||||
"url": "\$url.sha256"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user