diff --git a/bin/aurto b/bin/aurto index b6ff0ef..89f89fb 100755 --- a/bin/aurto +++ b/bin/aurto @@ -6,8 +6,8 @@ command=${1:-} arg1=${2:-} if [ "$command" == "add" ] && [ -n "$arg1" ]; then - echo "aurto: Running: \`aursync --no-view --rmdeps --no-confirm -C /var/lib/aurto-builder --repo=aurto ${*:2}\`" >&2 - aursync --no-view --rmdeps --no-confirm -C /var/lib/aurto-builder --repo=aurto "${@:2}" + echo "aurto: Running: \`aursync --no-view --rmdeps --no-confirm --chroot --repo=aurto ${*:2}\`" >&2 + aursync --no-view --rmdeps --no-confirm --chroot --repo=aurto "${@:2}" elif [ "$command" == "remove" ] && [ -n "$arg1" ]; then removed="" for pkg in "${@:2}"; do diff --git a/lib/check-aurto-git b/lib/check-aurto-git index f1954b9..8c5cb21 100755 --- a/lib/check-aurto-git +++ b/lib/check-aurto-git @@ -4,6 +4,7 @@ set -u SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +user=$(cat /usr/lib/aurto/user) command -v aurfetch >/dev/null 2>&1 || { echo >&2 "aurfetch not installed. Aborting."; exit 1; } function check_auto_updates { @@ -15,7 +16,8 @@ function check_auto_updates { before_rel=$(grep -m1 pkgrel= PKGBUILD | sed -e 's/^[^=]*=//g') installed_ver=$(pacman -Q "$dir" | sed -e 's/^[^ ]* //g') - arch-nspawn /var/lib/aurto-builder \ + # TODO this is pretty fragile relying on aurutils internals + arch-nspawn /var/lib/aurbuild/"$(uname -m)/$user" \ --bind="$SCRIPT_DIR"/tmp/"$dir" \ -u builduser \ /usr/bin/env bash -c " diff --git a/lib/update-aurto b/lib/update-aurto index de0da93..c5ea36c 100755 --- a/lib/update-aurto +++ b/lib/update-aurto @@ -13,8 +13,7 @@ fi pacman -Sy >/dev/null 2>&1 -sudo -u "$user" aursync --no-view --rmdeps --no-confirm --repo aurto \ - -C /var/lib/aurto-builder --update +sudo -u "$user" aursync --no-view --rmdeps --no-confirm --repo aurto --chroot --update if [ -e /usr/lib/aurto/check-vcs ]; then rm -f /usr/lib/aurto/check-vcs || true