From fa9908413badea0215ffc51f4a37963d98fd15af Mon Sep 17 00:00:00 2001 From: mfahampshire Date: Mon, 21 Aug 2023 15:40:03 +0200 Subject: [PATCH] minimal first version bump script --- documentation/bump_versions.sh | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100755 documentation/bump_versions.sh diff --git a/documentation/bump_versions.sh b/documentation/bump_versions.sh new file mode 100755 index 0000000000..507af1492e --- /dev/null +++ b/documentation/bump_versions.sh @@ -0,0 +1,17 @@ +#!/bin/bash +# this takes two args: platform release version and wallet release version. +# it then uses sed to bump them in the three book.toml files. +# +# e.g if the upcoming platform release was v1.1.29 and the release version 1.2.9 you'd run this as: +# `./bump_versions.sh "1.1.29" "1.2.9"` + +# array of project dirs +declare -a projects=("docs" "dev-portal" "operators") + +## now loop through the above array sed-ing the variable values in the book.toml files +for i in "${projects[@]}" +do + # sed the vars in the book.toml file for each project + sed -i 's/platform_release_version =.*/platform_release_version = "'$1'"/' "$i"/book.toml + sed -i 's/wallet_release_version =.*/wallet_release_version = "'$2'"/' "$i"/book.toml +done \ No newline at end of file