Added an option not to clone sc-release; fixes gh-82
This commit is contained in:
@@ -15,6 +15,7 @@ import org.springframework.cloud.release.internal.pom.ProjectPomUpdater;
|
||||
import org.springframework.cloud.release.internal.pom.ProjectVersion;
|
||||
import org.springframework.cloud.release.internal.pom.Projects;
|
||||
import org.springframework.cloud.release.internal.project.ProjectBuilder;
|
||||
import org.springframework.util.Assert;
|
||||
|
||||
/**
|
||||
* @author Marcin Grzejszczak
|
||||
@@ -119,6 +120,8 @@ public class Releaser {
|
||||
}
|
||||
|
||||
public void createEmail(ProjectVersion releaseVersion) {
|
||||
Assert.notNull(releaseVersion, "You must provide a release version for your project");
|
||||
Assert.notNull(releaseVersion.version, "You must provide a release version for your project");
|
||||
if (releaseVersion.isSnapshot()) {
|
||||
log.info("\nWon't create email template for a SNAPSHOT version");
|
||||
return;
|
||||
|
||||
@@ -59,6 +59,11 @@ public class ReleaserProperties {
|
||||
*/
|
||||
private String cloneDestinationDir;
|
||||
|
||||
/**
|
||||
* If {@code true} then should fill the map of versions from Git. If {@code false} then picks fixed versions
|
||||
*/
|
||||
private boolean fetchVersionsFromGit = true;
|
||||
|
||||
/**
|
||||
* GitHub OAuth token to be used to interact with GitHub repo
|
||||
*/
|
||||
@@ -127,6 +132,14 @@ public class ReleaserProperties {
|
||||
public void setNumberOfCheckedMilestones(Integer numberOfCheckedMilestones) {
|
||||
this.numberOfCheckedMilestones = numberOfCheckedMilestones;
|
||||
}
|
||||
|
||||
public boolean isFetchVersionsFromGit() {
|
||||
return this.fetchVersionsFromGit;
|
||||
}
|
||||
|
||||
public void setFetchVersionsFromGit(boolean fetchVersionsFromGit) {
|
||||
this.fetchVersionsFromGit = fetchVersionsFromGit;
|
||||
}
|
||||
}
|
||||
|
||||
public static class Pom {
|
||||
|
||||
Reference in New Issue
Block a user