fix: update pacman.conf Server URL on re-install (was stuck on localhost)

This commit is contained in:
arch_agent
2026-08-04 10:07:00 +02:00
parent b91d9815f3
commit 0f5ced5d9c
+3 -1
View File
@@ -40,7 +40,9 @@ Server = http://$SHIELD_HOST:$SHIELD_PORT/repo
SigLevel = Never"
if grep -q "^\[aur-shield\]" "$PACMAN_CONF"; then
echo "⚠ [aur-shield] already exists in $PACMAN_CONF — skipping"
echo "⚠ [aur-shield] already exists — updating server URL..."
sudo sed -i "/^\[aur-shield\]/,/^\[/ s|Server = .*|Server = http://$SHIELD_HOST:$SHIELD_PORT/repo|" "$PACMAN_CONF"
echo "✓ Updated repo server URL"
else
echo "Adding [aur-shield] to $PACMAN_CONF..."
sudo tee -a "$PACMAN_CONF" > /dev/null << EOF