dotfiles/modules/05-sound.sh

36 lines
703 B
Bash
Executable File

#!/usr/bin/env bash
# Install sound-related packages for Hyprland
SOUND_PACKAGES=(
pipewire
pipewire-alsa
pipewire-pulse
pipewire-jack
wireplumber
pavucontrol
pamixer
playerctl
alsa-utils
sof-firmware
)
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
systemctl --user enable --now pipewire pipewire-pulse wireplumber
echo "Sound packages installed and services enabled."