feat(system): comprehensive branding, styling, and system feature update
- Relocate themes to assets/themes/ and update all references. - Implement custom SDDM theme and Plymouth theme enhancements. - Add themed templates for Alacritty, Hyprland, Waybar, and other apps. - Introduce Makima key remapper module and configuration. - Add Voxtype and Walker configurations. - Implement systemd power management and timeout optimizations. - Add Nautilus-python extensions for LocalSend. - Update branding assets and ASCII art integration.
This commit is contained in:
35
bin/system/nomarchy-setup-dns
Executable file
35
bin/system/nomarchy-setup-dns
Executable file
@@ -0,0 +1,35 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Configure DNS declaratively for Nnomarchy NixOS.
|
||||
# Hybrid: updates /etc/nixos/state.json and runs sys-update.
|
||||
|
||||
STATE_FILE="/etc/nixos/state.json"
|
||||
|
||||
if [[ -z $1 ]]; then
|
||||
dns=$(gum choose --height 6 --header "Select DNS provider" Cloudflare Google DHCP Custom)
|
||||
else
|
||||
dns=$1
|
||||
fi
|
||||
|
||||
case "$dns" in
|
||||
Cloudflare|Google|DHCP)
|
||||
sudo jq ".dns = \"$dns\"" "$STATE_FILE" > /tmp/state.json && sudo mv /tmp/state.json "$STATE_FILE"
|
||||
;;
|
||||
|
||||
Custom)
|
||||
echo "Enter your DNS servers (space-separated, e.g. '192.168.1.1 1.1.1.1'):"
|
||||
read -r dns_servers
|
||||
|
||||
if [[ -z $dns_servers ]]; then
|
||||
echo "Error: No DNS servers provided."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Convert to JSON array
|
||||
dns_array=$(echo "$dns_servers" | jq -R 'split(" ")')
|
||||
sudo jq ".dns = \"Custom\" | .customDns = $dns_array" "$STATE_FILE" > /tmp/state.json && sudo mv /tmp/state.json "$STATE_FILE"
|
||||
;;
|
||||
esac
|
||||
|
||||
echo "DNS configured to $dns. Applying changes..."
|
||||
sudo sys-update
|
||||
Reference in New Issue
Block a user