chore(hygiene): final script cleanup and plymouth optimization
- Remove unused pkg and cmd helper scripts - Optimize Plymouth settings for cleaner boot in all environments - Skip hardware auto-detection logic in Live ISO environment
This commit is contained in:
@@ -1,11 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Returns true if any of the commands passed in as arguments are missing on the system.
|
||||
|
||||
for cmd in "$@"; do
|
||||
if ! command -v "$cmd" &>/dev/null; then
|
||||
exit 0
|
||||
fi
|
||||
done
|
||||
|
||||
exit 1
|
||||
@@ -21,6 +21,11 @@ fi
|
||||
# 3. Declarative hardware configuration check (nixos-hardware)
|
||||
# This part ensures that if we are on an installed system, the correct
|
||||
# nixos-hardware module is selected in the configuration.
|
||||
# Skip this in the Live ISO environment
|
||||
if [[ $USER == "nixos" ]] || [[ -f /etc/nixos/hosts/live-iso.nix ]]; then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
HW_FILE="/etc/nixos/hardware-selection.nix"
|
||||
if [ -w "$HW_FILE" ]; then
|
||||
PRODUCT_NAME=$(cat /sys/class/dmi/id/product_name 2>/dev/null || echo "Unknown")
|
||||
|
||||
@@ -1,15 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
PKG_NAME="$1"
|
||||
|
||||
if [ -z "$PKG_NAME" ]; then
|
||||
echo "Usage: nomarchy-pkg-missing <package-name>"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
nomarchy-pkg-present "$PKG_NAME"
|
||||
if [ $? -eq 0 ]; then
|
||||
exit 1
|
||||
else
|
||||
exit 0
|
||||
fi
|
||||
@@ -1,20 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
PKG_NAME="$1"
|
||||
|
||||
if [ -z "$PKG_NAME" ]; then
|
||||
echo "Usage: nomarchy-pkg-present <package-name>"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
STATE_FILE="$HOME/.config/home-manager/user-packages.json"
|
||||
|
||||
if [ ! -f "$STATE_FILE" ]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if jq -e ". | index(\"$PKG_NAME\")" "$STATE_FILE" >/dev/null; then
|
||||
exit 0
|
||||
else
|
||||
exit 1
|
||||
fi
|
||||
Reference in New Issue
Block a user