From 75c69d57debb100da41d4f61655b384bbee7ee8e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Reinhard=20N=C3=A4gele?= Date: Thu, 24 Jan 2019 15:46:07 +0100 Subject: [PATCH] Improve docs on releasing (#95) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Reinhard Nägele --- README.md | 18 ++++++++++++++++++ tag.sh | 4 ++-- 2 files changed, 20 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 2d0cab1c..b171cfd7 100644 --- a/README.md +++ b/README.md @@ -148,6 +148,14 @@ Build ct using Goreleaser. ## Releasing +### Prepare Release + +Before a release is created, versions have to be updated in the examples. +A pull request needs to be created for this, which should be merged right before the release is cut. +Here's a previous one for reference: https://github.com/helm/chart-testing/pull/89 + +### Create Release + CircleCI creates releases automatically when a new tag is pushed. Tags are created using `tag.sh`. ```console @@ -164,6 +172,16 @@ Create and push a tag. -s, --skip-push Skip pushing the tag ``` +By default, the script assumes that `origin` points to your own fork and that you have a remote `upstream` that points to the upstream `chart-testing` repo. +Run the script specifying the version for the new release. + +```console +./tag.sh --tag +``` + +Versions must start with a lower-case `v`, e. g. `v2.2.0`. + + ## Supported versions The previous MAJOR version will be supported for three months after each new MAJOR release. diff --git a/tag.sh b/tag.sh index bc021225..f635fd0d 100755 --- a/tag.sh +++ b/tag.sh @@ -52,7 +52,7 @@ main() { debug=true ;; -t|--tag) - if [ -n "${2:-}" ]; then + if [[ -n "${2:-}" ]]; then tag="$2" shift else @@ -62,7 +62,7 @@ main() { fi ;; -r|--remote) - if [ -n "${2:-}" ]; then + if [[ -n "${2:-}" ]]; then remote="$2" shift else