From 8b0fd930110adc594465e018ea93e3f41455b8ff Mon Sep 17 00:00:00 2001 From: Ryan Hughes Date: Wed, 20 May 2026 21:38:09 -0400 Subject: [PATCH] chown the package build dir to the builder user makepkg runs as the builder user and needs to write PKGDEST. /tmp/omarchy-pkg-build is created by root, so without an explicit chown the build aborts with 'You do not have write permission for the directory $PKGDEST'. --- builder/build-omarchy-packages.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/builder/build-omarchy-packages.sh b/builder/build-omarchy-packages.sh index 06389fa..d438ebc 100755 --- a/builder/build-omarchy-packages.sh +++ b/builder/build-omarchy-packages.sh @@ -27,12 +27,14 @@ rm -rf "$work_dir" mkdir -p "$work_dir" # makepkg refuses to run as root; create a builder user with passwordless -# sudo for pacman dep installation during the build. +# sudo for pacman dep installation during the build, and hand it ownership +# of the work dir so PKGDEST writes succeed. if ! id builder &>/dev/null; then useradd -m -s /bin/bash builder fi echo 'builder ALL=(ALL) NOPASSWD: /usr/bin/pacman' > /etc/sudoers.d/99-omarchy-pkg-builder chmod 440 /etc/sudoers.d/99-omarchy-pkg-builder +chown builder:builder "$work_dir" pacman -Sy --noconfirm