refactor: only install missing packages in sound and hyprland modules
This commit is contained in:
parent
0c014eb08d
commit
e6ff6f6c48
@ -14,7 +14,20 @@ SOUND_PACKAGES=(
|
|||||||
sof-firmware
|
sof-firmware
|
||||||
)
|
)
|
||||||
|
|
||||||
paru -S --needed --noconfirm "${SOUND_PACKAGES[@]}"
|
to_install=()
|
||||||
|
for pkg in "${SOUND_PACKAGES[@]}"; do
|
||||||
|
if ! paru -Q "$pkg" &>/dev/null; then
|
||||||
|
to_install+=("$pkg")
|
||||||
|
fi
|
||||||
|
|
||||||
|
done
|
||||||
|
|
||||||
|
if [ "${#to_install[@]}" -gt 0 ]; then
|
||||||
|
paru -S --noconfirm "${to_install[@]}"
|
||||||
|
echo "Sound packages installed."
|
||||||
|
else
|
||||||
|
echo "All sound packages already installed."
|
||||||
|
fi
|
||||||
|
|
||||||
# Enable and start PipeWire services
|
# Enable and start PipeWire services
|
||||||
systemctl --user enable --now pipewire pipewire-pulse wireplumber
|
systemctl --user enable --now pipewire pipewire-pulse wireplumber
|
||||||
|
|||||||
@ -21,6 +21,17 @@ HYPR_PACKAGES=(
|
|||||||
noto-fonts-emoji
|
noto-fonts-emoji
|
||||||
)
|
)
|
||||||
|
|
||||||
paru -S --needed --noconfirm "${HYPR_PACKAGES[@]}"
|
to_install=()
|
||||||
|
for pkg in "${HYPR_PACKAGES[@]}"; do
|
||||||
|
if ! paru -Q "$pkg" &>/dev/null; then
|
||||||
|
to_install+=("$pkg")
|
||||||
|
fi
|
||||||
|
|
||||||
echo "Hyprland and related tools installed and configured."
|
done
|
||||||
|
|
||||||
|
if [ "${#to_install[@]}" -gt 0 ]; then
|
||||||
|
paru -S --noconfirm "${to_install[@]}"
|
||||||
|
echo "Hyprland and related tools installed and configured."
|
||||||
|
else
|
||||||
|
echo "All Hyprland and related tools already installed."
|
||||||
|
fi
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user