extract yay call into bash script

This commit is contained in:
Dominic 2023-03-25 14:17:05 +01:00
parent b87e2b855a
commit f4ec72e937
Signed by: msrd0
GPG key ID: DCC8C247452E98F9

View file

@ -25,9 +25,12 @@ runs:
echo "user ALL=(ALL:ALL) NOPASSWD: ALL" >/etc/sudoers.d/user
sudo -u user -- bash -c "cd ~ && git clone https://aur.archlinux.org/yay.git && cd yay && makepkg -si --noconfirm"
echo "#!/bin/bash -ex" >/usr/local/bin/yay.sh
echo "sudo -u user -- yay \"\${@}\"" >>/usr/local/bin/yay.sh
chmod +x /usr/local/bin/yay.sh
chmod 777 .
sudo -u user PACMAN="sudo -u user -- yay" makepkg -s --noconfirm
sudo -u user PACMAN="/usr/local/bin/yay.sh" makepkg -s --noconfirm
sudo -u user makepkg --printsrcinfo >.SRCINFO.new
'