Compare commits

..

No commits in common. "61f8b8127cf50807a7a0792ed9f3182c6dddc6e2" and "b73c93a31e17a9a09d0b8f46ef74513d3fbe6562" have entirely different histories.

7 changed files with 35 additions and 125 deletions

24
nixos/flake.lock generated
View file

@ -62,11 +62,11 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1763334038, "lastModified": 1760862643,
"narHash": "sha256-LBVOyaH6NFzQ3X/c6vfMZ9k4SV2ofhpxeL9YnhHNJQQ=", "narHash": "sha256-PXwG0TM7Ek87DNx4LbGWuD93PbFeKAJs4FfALtp7Wo0=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "4c8cdd5b1a630e8f72c9dd9bf582b1afb3127d2c", "rev": "33c6dca0c0cb31d6addcd34e90a63ad61826b28c",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -77,11 +77,11 @@
}, },
"nixpkgs-unstable": { "nixpkgs-unstable": {
"locked": { "locked": {
"lastModified": 1763283776, "lastModified": 1760878510,
"narHash": "sha256-Y7TDFPK4GlqrKrivOcsHG8xSGqQx3A6c+i7novT85Uk=", "narHash": "sha256-K5Osef2qexezUfs0alLvZ7nQFTGS9DL2oTVsIXsqLgs=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "50a96edd8d0db6cc8db57dab6bb6d6ee1f3dc49a", "rev": "5e2a59a5b1a82f89f2c7e598302a9cacebb72a67",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -174,11 +174,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1763417348, "lastModified": 1760998189,
"narHash": "sha256-n5xDOeNN+smocQp3EMIc11IzBlR9wvvTIJZeL0g33Fs=", "narHash": "sha256-ee2e1/AeGL5X8oy/HXsZQvZnae6XfEVdstGopKucYLY=",
"owner": "Mic92", "owner": "Mic92",
"repo": "sops-nix", "repo": "sops-nix",
"rev": "3f66a7fb9626a9a9c077612ef10a0ce396286c7d", "rev": "5a7d18b5c55642df5c432aadb757140edfeb70b3",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -265,11 +265,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1763352549, "lastModified": 1761105987,
"narHash": "sha256-hzLnXm0v1snDENpF3KvUQBO8XOAh45qg+y4D46K3rz8=", "narHash": "sha256-d01CGcdNlsqIn4ncGCWHM0Velnii/Ggef1iybQvEOfc=",
"owner": "youwen5", "owner": "youwen5",
"repo": "zen-browser-flake", "repo": "zen-browser-flake",
"rev": "5d002fcacbc5423090f2bba19818adda471fe0c8", "rev": "e7d9fefd8665be5d4c77466140f21a15f6d29e93",
"type": "github" "type": "github"
}, },
"original": { "original": {

View file

@ -14,7 +14,5 @@ in {
]; ];
programs.waybar.enable = true; programs.waybar.enable = true;
services.atd.enable = true; # Command scheduler
}; };
} }

15
scripts/sunset.sh Executable file
View file

@ -0,0 +1,15 @@
#!/usr/bin/env bash
# Script to disable for an hour or immediately continue wlsunset. 'Toggle'
# Check if wlsunset is still running
pid=$(pgrep wlsunset)
if [[ -z ${pid} ]] ; then
# Start wlsunset right away.
wlsunset -l 50.50 -L 4.00 -t 3000 -T 6500 &
else
# Currently stop wlsunset but restart in an hour.
kill ${pid}
notify-send 'Stopping sunset' 'Restarting in an hour'
at now +1 hours -f "${0}"
fi

View file

@ -1,52 +0,0 @@
#!/usr/bin/env bash
# Script to disable for an hour or immediately continue wlsunset. 'Toggle'
# Queue for at, check man page for options
ATQUEUE='T'
# Get current state
pid=$(pgrep wlsunset)
while getopts ":g" option; do
case "${option}" in
g)
if [[ -z "${pid}" ]]; then
state='active'
tooltip='Turn off nightlight'
class='activated'
else
state='inactive'
tooltip='Turn on nightlight'
class='none'
fi
printf '{"alt": "%s", "tooltip": "%s", "class": "%s" }' \
"${state}" "${tooltip}" "${class}"
exit 0
;;
*)
echo 'Invalid option'
exit 1
;;
esac
done
# Toggle
if [[ -z ${pid} ]] ; then
# Clear queue
for job in $(at -l -q "${ATQUEUE}" | cut -f1); do
at -r "${job}"
done
if [ "$( command -v wlsunset )" ]; then
notify-send 'Starting nightlight'
wlsunset -l 50.50 -L 4.00 -t 3000 -T 6500 &
else
notify-send 'Nightlight is not available'
exit 1
fi
else
# Currently stop wlsunset but restart in an hour.
kill ${pid}
notify-send 'Stopping nightlight' 'Restarting in an hour'
at now +1 hours -f "${0}" -q "${ATQUEUE}"
fi

View file

@ -51,7 +51,6 @@
"privacy", "privacy",
"tray", "tray",
"group/control-center", "group/control-center",
"group/display",
"group/network", "group/network",
"pulseaudio", "pulseaudio",
"group/power", "group/power",

View file

@ -1,15 +1,4 @@
{ {
"backlight": {
"device": "intel_backlight",
"format": "{percent}% {icon}",
"format-icons": [
"\uf111", /* */
"\uf185" /* */
],
"on-click": "brightnessctl -sq set 0",
"on-click-right": "wl-mirror $(hyprctl monitors -j | jq --raw-output '.[] | select(.focused) | .name')"
},
"battery": { "battery": {
"format": "{capacity}% {icon}", "format": "{capacity}% {icon}",
"format-alt": "{time} {icon}", "format-alt": "{time} {icon}",
@ -82,12 +71,6 @@
"tooltip": false "tooltip": false
}, },
"custom/display": {
"format": "\ue163", /* */
"tooltip": false,
"on-click": "wdisplays"
},
"custom/meta": { "custom/meta": {
"format": "\uf17c", /* */ "format": "\uf17c", /* */
"tooltip": false, "tooltip": false,
@ -151,19 +134,6 @@
"tooltip": true "tooltip": true
}, },
"custom/toggle-nightlight": {
"exec": "bash ${SCRIPT_DIR}/toggle-nightlight.sh -g",
"interval": 60,
"return-type": "json",
"on-click": "bash ${SCRIPT_DIR}/toggle-nightlight.sh",
"format": "{icon}",
"format-icons": {
"active": "\uf186", /* */
"inactive": "\uf0eb" /* */
},
"tooltip": true
},
"custom/toggle-notifications": { "custom/toggle-notifications": {
"exec": "bash ${SCRIPT_DIR}/toggle-notifications.sh -g", "exec": "bash ${SCRIPT_DIR}/toggle-notifications.sh -g",
"interval": 60, "interval": 60,
@ -193,31 +163,12 @@
"group/control-center": { "group/control-center": {
"orientation": "inherit", "orientation": "inherit",
"modules": [ "modules": [
/* Preview */
"custom/control-center", "custom/control-center",
/* Left-most */
"group/language", "group/language",
"custom/toggle-notifications" /* "hyprland/language", "sway/language", */
/* Right-most */ "custom/toggle-notifications",
],
"drawer": {
"transition-duration": 500,
"transition-left-to-right": false,
"children-class": "drawer-child"
}
},
"group/display": {
"orientation": "inherit",
"modules": [
/* Preview */
"custom/display",
/* Most-left */
"idle_inhibitor",
"custom/toggle-nightlight",
"custom/toggle-light-dark", "custom/toggle-light-dark",
"backlight" "bluetooth"
/* Most-right */
], ],
"drawer": { "drawer": {
"transition-duration": 500, "transition-duration": 500,
@ -248,7 +199,6 @@
/* Preview */ /* Preview */
"network", "network",
/* Most-left */ /* Most-left */
"bluetooth",
"custom/toggle-tailscale" "custom/toggle-tailscale"
/* Most-right */ /* Most-right */
], ],
@ -270,7 +220,8 @@
"custom/system-hibernate", "custom/system-hibernate",
"custom/system-sleep", "custom/system-sleep",
"custom/system-lock", "custom/system-lock",
"power-profiles-daemon" "power-profiles-daemon",
"idle_inhibitor"
/* Most-right */ /* Most-right */
], ],
"drawer": { "drawer": {

View file

@ -82,13 +82,12 @@ window#waybar {
#privacy, #privacy,
#privacy-item, #privacy-item,
#privacy-item.screenshare, #privacy-item.screenshare,
#privacy-item.audio-in, #privacy-item.audio-in {
#privacy-item.audio-out {
background-color: @safety; background-color: @safety;
} }
#privacy-item { #privacy-item.screenshare {
padding: 0; background-color: #000000;
} }
#pulseaudio.muted { #pulseaudio.muted {