diff --git a/install.sh b/install.sh index 1dd900a..c5f3809 100755 --- a/install.sh +++ b/install.sh @@ -1,14 +1,66 @@ #!/usr/bin/env bash -# install.sh: Stow all packages in this dotfiles repo. +# install.sh: Install dependencies and stow all packages. # Run this after cloning on a new machine. set -euo pipefail DOTFILES_DIR="$(cd "$(dirname "$0")" && pwd)" +# --------------------------------------------------------------------------- +# Dependencies (Fedora) +# --------------------------------------------------------------------------- + +DNF_PACKAGES=( + stow + # sway ecosystem + autotiling + swayidle + # bar & notifications + mako + libnotify # notify-send + # terminal & launcher + fuzzel + # audio & display + wireplumber # wpctl + pipewire-utils # pactl + brightnessctl + alsa-utils # speaker-test + # screen recording + wf-recorder + slurp + zenity + ffmpeg # needs RPM Fusion: https://rpmfusion.org + # misc + jq + firefox +) + +echo "Installing dnf packages..." +sudo dnf install -y "${DNF_PACKAGES[@]}" + +# --------------------------------------------------------------------------- +# Packages not in Fedora repos — install manually if missing +# --------------------------------------------------------------------------- + +warn_missing() { + local cmd="$1" msg="$2" + if ! command -v "$cmd" &>/dev/null; then + echo "WARNING: '$cmd' not found — $msg" + fi +} + +warn_missing eww "install from https://github.com/elkowar/eww/releases" +warn_missing wezterm "install from https://wezfurlong.org/wezterm/install/linux.html" + +# --------------------------------------------------------------------------- +# Stow all packages +# --------------------------------------------------------------------------- + +echo "" +echo "Stowing dotfiles..." for PACKAGE in "$DOTFILES_DIR"/*/; do PACKAGE="$(basename "$PACKAGE")" - echo "Stowing: $PACKAGE" + echo " $PACKAGE" stow --dir="$DOTFILES_DIR" --target="$HOME" --restow "$PACKAGE" done