summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xbumpPkgrel15
-rwxr-xr-xbumpVersion10
2 files changed, 21 insertions, 4 deletions
diff --git a/bumpPkgrel b/bumpPkgrel
index c0db9229..a371d6a9 100755
--- a/bumpPkgrel
+++ b/bumpPkgrel
@@ -17,14 +17,23 @@ if [ $# -eq 1 ]; then
cd "$(dirname "$0")"
pkg="${1%/}"
+ cd "${pkg}"
eval "$(
- grep '^pkgrel=' "${pkg}/PKGBUILD"
+ grep '^pkgrel=' 'PKGBUILD'
)"
sed -i '
s@^\(pkgrel=\)\('"'"'\?\)[0-9]\+\2$@\1'"$((pkgrel+1))"'@
- ' "${pkg}/PKGBUILD"
+ ' 'PKGBUILD'
if ${commit}; then
- git commit "${pkg}/PKGBUILD" -m "${pkg}: rebuild"
+ if [ -d '.git' ] || [ -f '.git' ]; then
+ makepkg --printsrcinfo > .SRCINFO
+ git commit 'PKGBUILD' '.SRCINFO' -m "${pkg}: rebuild"
+ git push || exit 1
+ cd ..
+ git commit "${paket}" -m "${pkg}: rebuild"
+ else
+ git commit 'PKGBUILD' -m "${pkg}: rebuild"
+ fi
fi
else
diff --git a/bumpVersion b/bumpVersion
index 8ccd4511..30523ecd 100755
--- a/bumpVersion
+++ b/bumpVersion
@@ -172,6 +172,14 @@ if [ "${paket}" != 'qgis-git' ]; then
makepkg -fcsr --noconfirm --asdeps || exit 1
namcap "$(makepkg --packagelist)" || exit 1
fi
-git commit PKGBUILD -m "${paket} ${pkgver}-${pkgrel} -> ${remVer}-1"
+if [ -d '.git' ] || [ -f '.git' ]; then
+ makepkg --printsrcinfo > .SRCINFO
+ git commit 'PKGBUILD' '.SRCINFO' -m "${paket} ${pkgver}-${pkgrel} -> ${remVer}-1"
+ git push || exit 1
+ cd ..
+ git commit "${paket}" -m "${paket} ${pkgver}-${pkgrel} -> ${remVer}-1"
+else
+ git commit 'PKGBUILD' -m "${paket} ${pkgver}-${pkgrel} -> ${remVer}-1"
+fi
>&2 echo '... done'