- Reorganize directory structure into core/, features/, and themes/ - Colocate application Nix logic, configs, scripts, and theme overrides - Implement 'Inversion of Control' for theming: apps now pull theme-specific layouts - Update flake.nix and shared library paths to match the new structure - Document the new Feature-Centric architecture in README.md
18 lines
465 B
Bash
Executable File
18 lines
465 B
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
# Toggles wifi power saving declaratively.
|
|
# Usage: nomarchy-wifi-powersave <on|off>
|
|
|
|
STATE_FILE="/etc/nixos/state.json"
|
|
|
|
case "$1" in
|
|
on) value="true" ;;
|
|
off) value="false" ;;
|
|
*) echo "Usage: nomarchy-wifi-powersave <on|off>"; exit 1 ;;
|
|
esac
|
|
|
|
sudo jq --argjson val "$value" '.wifi.powersave = $val' "$STATE_FILE" > /tmp/state.json && sudo mv /tmp/state.json "$STATE_FILE"
|
|
|
|
echo "Wifi powersave set to $1. Applying changes..."
|
|
sudo sys-update
|