From aa63cce5e0bb84776d4aa2d495b337a7ea14a753 Mon Sep 17 00:00:00 2001 From: MatMoul Date: Sat, 11 Mar 2023 03:46:38 +0100 Subject: [PATCH] Update makerelease --- makerelease | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/makerelease b/makerelease index 690233a..c089810 100755 --- a/makerelease +++ b/makerelease @@ -13,8 +13,9 @@ if [ ! "${?}" = "1" ]; then fi clear -branch=$(git rev-parse --abbrev-ref HEAD) -read -p "Current branch is ${branch}. Continue ? (y/N)" choice +declare BRANCH="" +BRANCH=$(git rev-parse --abbrev-ref HEAD) +read -r -p "Current branch is ${BRANCH}. Continue ? (y/N)" choice case "${choice}" in n|N|'' ) echo "Cancel !" @@ -31,16 +32,19 @@ esac # Ready to update : -version=${1} +declare VERSION +VERSION=${1} -git commit -a -m "Version ${version}" +sed -i 's/pkgver=.*/pkgver='"${VERSION}"'/' packaging/archlinux/dokytree/PKGBUILD + +git commit -a -m "Version ${VERSION}" git push git checkout main git merge dev git push -git tag -a "v${version}" -m "Version ${version}" +git tag -a "v${VERSION}" -m "Version ${VERSION}" git push --tags git checkout "${branch}"