Merge pull request #262 from ryanjbaxter/publish-antora-docs
Run command from within src directory
This commit is contained in:
@@ -104,7 +104,7 @@ releaser:
|
||||
antora:
|
||||
spring-docs-actions-url: https://github.com/spring-io/spring-doc-actions
|
||||
spring-docs-actions-tag: v0.0.16
|
||||
sync-antora-docs-command: "./rsync-antora-reference/src/action.sh"
|
||||
sync-antora-docs-command: "./action.sh"
|
||||
meta-release:
|
||||
enabled: false
|
||||
release-train-project-name: spring-cloud-release
|
||||
|
||||
@@ -1178,8 +1178,8 @@ public class ReleaserProperties implements Serializable {
|
||||
public String toString() {
|
||||
return "Maven{" + "buildCommand='" + this.buildCommand + '\'' + ", deployCommand='" + this.deployCommand
|
||||
+ '\'' + ", publishDocsCommand=" + this.publishDocsCommand + "generateReleaseTrainDocsCommand='"
|
||||
+ this.generateReleaseTrainDocsCommand + '\'' + ", runAntoraCommand= "
|
||||
+ runAntoraCommand + ", waitTimeInMinutes=" + this.waitTimeInMinutes + '}';
|
||||
+ this.generateReleaseTrainDocsCommand + '\'' + ", runAntoraCommand= " + runAntoraCommand
|
||||
+ ", waitTimeInMinutes=" + this.waitTimeInMinutes + '}';
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -183,13 +183,13 @@ public class ProjectCommandExecutor {
|
||||
String command = new CommandPicker(properties).publishAntoraDocsCommand(project, properties);
|
||||
log.info("Executing command for publishing Antora docs " + command + " / " + properties);
|
||||
String[] commands = command.split(" ");
|
||||
//TODO fix this hack
|
||||
// TODO fix this hack
|
||||
for (int i = 0; i < commands.length; i++) {
|
||||
if (commands[i].contains("{{cat-key}}")) {
|
||||
commands[i] = commands[i].replace("{{cat-key}}", "\"$(cat $DOCS_SERVER_SSH_KEY)\"");
|
||||
}
|
||||
}
|
||||
runCommand(properties, antoraDocsProject.getAbsolutePath(), command.split(" "));
|
||||
runCommand(properties, antoraDocsProject.getAbsolutePath() + "/rsync-antora-reference/src", command.split(" "));
|
||||
}
|
||||
|
||||
public void publishDocs(ReleaserProperties properties, ProjectVersion originalVersion,
|
||||
@@ -342,10 +342,9 @@ class CommandPicker {
|
||||
ProjectVersion version = new ProjectVersion(project);
|
||||
String repo = properties.getGit().getOrgName() + "/" + version.projectName;
|
||||
// TODO this needs to be a property
|
||||
return "./rsync-antora-reference/src/action.sh"
|
||||
return "./action.sh"
|
||||
+ " --docs-username \"$DOCS_SERVER_SSH_USER\" --docs-host \"docs.spring.io\" --docs-ssh-key {{cat-key}} --docs-ssh-host-key \"#\" --site-path \""
|
||||
+ project.getAbsolutePath() + "/target/antora/site\" --github-repository \"" + repo
|
||||
+ "\" --dry-run";
|
||||
+ project.getAbsolutePath() + "/target/antora/site\" --github-repository \"" + repo + "\" --dry-run";
|
||||
}
|
||||
|
||||
String version() {
|
||||
|
||||
Reference in New Issue
Block a user