#!/bin/bash pacman -Syu --noconfirm useradd build -m echo 'build ALL=(ALL) NOPASSWD: ALL' >> /etc/sudoers chown -R build:build * for d in */ ; do echo "$d" cd "$d" sudo -u build sh -c 'makepkg -s --skippgpcheck' if [ $? -eq 0 ]; then PKG=$(*.pkg.tar.zst) cp $PKG /repo/ repo-add /repo/nyyu.db.tar.zst $PKG fi cd .. done