Skip to content

Commit

Permalink
Patch latest version number in README
Browse files Browse the repository at this point in the history
  • Loading branch information
ewoutp committed Apr 3, 2018
1 parent a07eb76 commit 90e6ea1
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 0 deletions.
4 changes: 4 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -268,6 +268,10 @@ endif

# Release building

.PHONY: patch-readme
patch-readme:
$(ROOTDIR)/scripts/patch_readme.sh $(VERSION_MAJOR_MINOR_PATCH)

.PHONY: docker-push
docker-push: docker
ifneq ($(DOCKERNAMESPACE), arangodb)
Expand Down
16 changes: 16 additions & 0 deletions scripts/patch_readme.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#!/bin/bash

# Updates the installation instructions in README.md to reflect the current
# version.

VERSION=$1

if [ -z $VERSION ]; then
echo "Specify a version argument"
exit 1
fi

f=README.md
sed -e "s@^kubectl apply -f https://raw.githubusercontent.com/arangodb/kube-arangodb/.*/manifests/crd.yaml\$@kubectl apply -f https://raw.githubusercontent.com/arangodb/kube-arangodb/${VERSION}/manifests/crd.yaml@g" -i "" $f
sed -e "s@^kubectl apply -f https://raw.githubusercontent.com/arangodb/kube-arangodb/.*/manifests/arango-deployment.yaml\$@kubectl apply -f https://raw.githubusercontent.com/arangodb/kube-arangodb/${VERSION}/manifests/arango-deployment.yaml@g" -i "" $f
sed -e "s@^kubectl apply -f https://raw.githubusercontent.com/arangodb/kube-arangodb/.*/manifests/arango-storage.yaml\$@kubectl apply -f https://raw.githubusercontent.com/arangodb/kube-arangodb/${VERSION}/manifests/arango-storage.yaml@g" -i "" $f
1 change: 1 addition & 0 deletions tools/release/release.go
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ func main() {
"IMAGETAG": version,
"MANIFESTSUFFIX": "-",
})
make("patch-readme", nil)
make("build-ghrelease", nil)
gitCommitAll(fmt.Sprintf("Updated manifest to %s", version)) // Commit manifest
gitTag(version)
Expand Down

0 comments on commit 90e6ea1

Please sign in to comment.