From fb6da5cbb15aa771299a4b06202161b823894b4a Mon Sep 17 00:00:00 2001 From: Nicolas Ruflin Date: Mon, 27 Nov 2017 21:38:32 +1100 Subject: [PATCH] Fix README.md link in packages (#5715) The links in the README.md file are broken for the 6.0 release. The reason is that gotpl interprets 6.0 and makes 6 out of it. Add "..." around fixes the issue. --- CHANGELOG.asciidoc | 2 ++ dev-tools/packer/xgo-scripts/before_build.sh | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.asciidoc b/CHANGELOG.asciidoc index bcf14a306e7..182599b0054 100644 --- a/CHANGELOG.asciidoc +++ b/CHANGELOG.asciidoc @@ -30,6 +30,8 @@ https://github.com/elastic/beats/compare/v6.0.0...master[Check the HEAD diff] *Affecting all Beats* +- Fix documentation links in README.md files. {pull}5710[5710] + *Auditbeat* *Filebeat* diff --git a/dev-tools/packer/xgo-scripts/before_build.sh b/dev-tools/packer/xgo-scripts/before_build.sh index c9863575c3c..d8e623d59dc 100755 --- a/dev-tools/packer/xgo-scripts/before_build.sh +++ b/dev-tools/packer/xgo-scripts/before_build.sh @@ -54,7 +54,8 @@ fi cat ${ES_BEATS}/libbeat/docs/version.asciidoc >> ${PREFIX}/package.yml # Make variable naming of doc-branch compatible with gotpl. Generate and copy README.md into homedir -sed -i -e 's/:doc-branch/doc_branch/g' ${PREFIX}/package.yml +# Add " to the version as gotpl interprets 6.0 as 6 +sed -i -e 's/:doc-branch: \([0-9]*.[0-9]*\)/doc_branch: "\1" /g' ${PREFIX}/package.yml # Create README file /go/bin/gotpl /templates/readme.md.j2 < ${PREFIX}/package.yml > ${PREFIX}/homedir/README.md