From 2e1e0c1bbc13bc909fb4f7cd7e57407dace94bc7 Mon Sep 17 00:00:00 2001 From: MedzikUser Date: Sun, 22 May 2022 20:09:50 +0200 Subject: [PATCH] fix(scripts): fix auto-update --- scripts/auto-update.sh | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/scripts/auto-update.sh b/scripts/auto-update.sh index 9ba1b7bb..d490f202 100755 --- a/scripts/auto-update.sh +++ b/scripts/auto-update.sh @@ -6,6 +6,7 @@ : "${GIT_PUSH_PACKAGES:=false}" SCRIPT_DIR="$(realpath "$(dirname "$0")")" +SRC_DIR="$(realpath "$(dirname "${SCRIPT_DIR}")")" source "${SCRIPT_DIR}/lib/parse-conf.sh" @@ -20,6 +21,8 @@ update-package() { eval "$(parse-conf ${pkgdir})" + cd "${SRC_DIR}" + # check the package updates from AUR if [ ! -f "${pkgdir}/PKGBUILD" ] then @@ -106,7 +109,9 @@ update-package() { # Update package checksums cd "${pkgdir}" - updpkgsums + chown -R build . + su -c 'updpkgsums' build + cd "${SRC_DIR}" if [ "${GIT_COMMIT_PACKAGES}" = "true" ] then @@ -145,7 +150,9 @@ update-package() { # Update package checksums cd "${pkgdir}" - updpkgsums + chown -R build . + su -c 'updpkgsums' build + cd "${SRC_DIR}" if [ "${GIT_COMMIT_PACKAGES}" = "true" ] then