style(install): simplify section comments to plain # style

This commit is contained in:
sankalp committed 2026-07-18 19:03:23 +05:45
1 parent 591017f6e5
commit 0fd5d3ea28
1 file changed
+18 -18
+18 -18
View File
@@ -17,7 +17,7 @@ set -e
set -u set -u
set -o pipefail set -o pipefail
# ── CLI flags ────────────────────────────────────────────────────── # CLI flags
AUTO_YES=false AUTO_YES=false
DRY_RUN=false DRY_RUN=false
for arg in "$@"; do for arg in "$@"; do
@@ -39,7 +39,7 @@ done
REPO_URL="https://github.com/S4NKALP/Modus.git" REPO_URL="https://github.com/S4NKALP/Modus.git"
INSTALL_DIR="$HOME/.config/Modus" INSTALL_DIR="$HOME/.config/Modus"
# ── Package definitions ──────────────────────────────────────────── # Package definitions
PACKAGES=( PACKAGES=(
uv uv
fabric-cli-git fabric-cli-git
@@ -91,7 +91,7 @@ PACKAGES=(
ffmpeg ffmpeg
) )
# ── Colors ───────────────────────────────────────────────────────── # Colors
if [ -t 1 ]; then if [ -t 1 ]; then
GREEN=$(tput setaf 2) GREEN=$(tput setaf 2)
YELLOW=$(tput setaf 3) YELLOW=$(tput setaf 3)
@@ -113,7 +113,7 @@ INFO="ℹ"
WARN="⚠" WARN="⚠"
BULLET="•" BULLET="•"
# ── Helpers ──────────────────────────────────────────────────────── # Helpers
header() { header() {
echo "" echo ""
echo -e " ${BOLD}${CYAN}╔══════════════════════════════════════════════╗${RESET}" echo -e " ${BOLD}${CYAN}╔══════════════════════════════════════════════╗${RESET}"
@@ -189,7 +189,7 @@ spinner() {
return $rc return $rc
} }
# ── Cleanup ──────────────────────────────────────────────────────── # Cleanup
cleanup() { cleanup() {
if [ -n "${SUDO_KEEPER_PID:-}" ]; then if [ -n "${SUDO_KEEPER_PID:-}" ]; then
kill "$SUDO_KEEPER_PID" 2>/dev/null || true kill "$SUDO_KEEPER_PID" 2>/dev/null || true
@@ -197,7 +197,7 @@ cleanup() {
} }
trap cleanup EXIT INT TERM trap cleanup EXIT INT TERM
# ── Banner ───────────────────────────────────────────────────────── # Banner
clear clear
header header
@@ -205,7 +205,7 @@ echo -e " ${BOLD}A hackable shell for Hyprland${RESET}"
echo -e " ${DIM}https://github.com/S4NKALP/Modus${RESET}" echo -e " ${DIM}https://github.com/S4NKALP/Modus${RESET}"
echo "" echo ""
# ── Pre-flight checks ───────────────────────────────────────────── # Pre-flight checks
section "Pre-flight checks" section "Pre-flight checks"
step "Checking operating system..." step "Checking operating system..."
@@ -229,7 +229,7 @@ if ! command -v git &>/dev/null; then
fi fi
success "git found" success "git found"
# ── Package list ────────────────────────────────────────────────── # Package list
section "Packages" section "Packages"
if [ "$DRY_RUN" = true ]; then if [ "$DRY_RUN" = true ]; then
@@ -247,7 +247,7 @@ if ! confirm "Proceed with installation?"; then
exit 0 exit 0
fi fi
# ── Sudo ─────────────────────────────────────────────────────────── # Sudo
section "Permissions" section "Permissions"
info "Some packages require root privileges" info "Some packages require root privileges"
@@ -264,7 +264,7 @@ while true; do
done 2>/dev/null & done 2>/dev/null &
SUDO_KEEPER_PID=$! SUDO_KEEPER_PID=$!
# ── AUR helper ───────────────────────────────────────────────────── # AUR helper
section "AUR helper" section "AUR helper"
AUR="" AUR=""
@@ -293,7 +293,7 @@ else
success "yay-bin installed" success "yay-bin installed"
fi fi
# ── Repository ───────────────────────────────────────────────────── # Repository
section "Repository" section "Repository"
if [ -d "$INSTALL_DIR" ]; then if [ -d "$INSTALL_DIR" ]; then
@@ -307,7 +307,7 @@ else
fi fi
info "${INSTALL_DIR}" info "${INSTALL_DIR}"
# ── Install packages ────────────────────────────────────────────── # Install packages
section "Installing packages" section "Installing packages"
step "Syncing databases..." step "Syncing databases..."
@@ -340,7 +340,7 @@ else
done done
fi fi
# ── Build native modules ────────────────────────────────────────── # Build native modules
section "Building native modules" section "Building native modules"
# Global Menu shim # Global Menu shim
@@ -373,7 +373,7 @@ else
warn "App-capture source not found — skipped" warn "App-capture source not found — skipped"
fi fi
# ── Hyprland config ─────────────────────────────────────────────── # Hyprland config
section "Hyprland configuration" section "Hyprland configuration"
HYPR_CONFIG="$HOME/.config/hypr/hyprland.lua" HYPR_CONFIG="$HOME/.config/hypr/hyprland.lua"
@@ -408,7 +408,7 @@ else
warn "hypridle.conf not found — skipped" warn "hypridle.conf not found — skipped"
fi fi
# ── Environment ─────────────────────────────────────────────────── # Environment
section "Global environment" section "Global environment"
APP_CONF_DIR="$HOME/.config/environment.d" APP_CONF_DIR="$HOME/.config/environment.d"
@@ -432,7 +432,7 @@ for entry in "GTK_MODULES DEFAULT=appmenu-gtk-module" "UBUNTU_MENUPROXY DEFAULT=
done done
success "pam_environment updated" success "pam_environment updated"
# ── Matugen ──────────────────────────────────────────────────────── # Matugen
section "Matugen" section "Matugen"
MATUGEN_CONFIG="$HOME/.config/matugen/config.toml" MATUGEN_CONFIG="$HOME/.config/matugen/config.toml"
@@ -469,7 +469,7 @@ else
info "Install matugen first, then re-run this script" info "Install matugen first, then re-run this script"
fi fi
# ── Launch ───────────────────────────────────────────────────────── # Launch
section "Launch" section "Launch"
step "Stopping existing instances..." step "Stopping existing instances..."
@@ -490,7 +490,7 @@ else
warn "Modus may not have started — check logs" warn "Modus may not have started — check logs"
fi fi
# ── Summary ──────────────────────────────────────────────────────── # Summary
echo "" echo ""
echo -e " ${GREEN}${BOLD}╔══════════════════════════════════════════╗${RESET}" echo -e " ${GREEN}${BOLD}╔══════════════════════════════════════════╗${RESET}"
echo -e " ${GREEN}${BOLD}║${RESET} ${GREEN}${BOLD}║${RESET}" echo -e " ${GREEN}${BOLD}║${RESET} ${GREEN}${BOLD}║${RESET}"