From 4da4c0d678df2b9451480f0a624410de50665adc Mon Sep 17 00:00:00 2001 From: Florian Pritz Date: Sun, 6 Jul 2014 21:14:51 +0200 Subject: upgpkg: allow to change _newpkgver from the pre_upgrade hook Signed-off-by: Florian Pritz --- upgpkg | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'upgpkg') diff --git a/upgpkg b/upgpkg index 2c3f677..1c58296 100755 --- a/upgpkg +++ b/upgpkg @@ -7,7 +7,7 @@ # I place this script in the public domain. -VERSION=0.5 +VERSION=0.6 # from makepkg unset ALL_OFF BOLD BLUE GREEN RED YELLOW @@ -100,7 +100,7 @@ if [[ $(vercmp $1 $pkgver) -le 0 ]]; then warn "New version (%s) older or equal to current %s" "$1" "$pkgver" fi -sed -i "s/pkgver=.*$/pkgver=$1/g" PKGBUILD +sed -i "s/pkgver=.*$/pkgver=$_newpkgver/g" PKGBUILD sed -i "s/pkgrel=.*$/pkgrel=1/g" PKGBUILD makepkg -g || exit 1 # replace the first checksum line with all checksums, remove all other checksums -- cgit v1.2.3-24-g4f1b