Compare commits
No commits in common. "02d29fb799347d18897765bd012a6b442a9da465" and "183490c955a8fddc7b48c019ad39c5472f938072" have entirely different histories.
02d29fb799
...
183490c955
|
@ -1,10 +0,0 @@
|
||||||
#!/usr/bin/env bash
|
|
||||||
|
|
||||||
msgTag="lightdunst"
|
|
||||||
|
|
||||||
brightnessctl set "$1"
|
|
||||||
|
|
||||||
light="$(brightnessctl -m | cut -d, -f4)"
|
|
||||||
dunstify -a "changeLight" -u low \
|
|
||||||
-h string:x-dunst-stack-tag:$msgTag \
|
|
||||||
-h int:value:"$light" "Brightness: $light"
|
|
|
@ -8,9 +8,8 @@ let username = "rachel";
|
||||||
exec ${hpkgs.haskell-language-server}/bin/haskell-language-server-wrapper "$@"
|
exec ${hpkgs.haskell-language-server}/bin/haskell-language-server-wrapper "$@"
|
||||||
'';
|
'';
|
||||||
rzk = hpkgs.rzk;
|
rzk = hpkgs.rzk;
|
||||||
vol = pkgs.writeScript "vol" (builtins.readFile ./vol.sh);
|
in
|
||||||
light = pkgs.writeScript "light" (builtins.readFile ./light.sh);
|
{
|
||||||
in rec {
|
|
||||||
home = {
|
home = {
|
||||||
username = username;
|
username = username;
|
||||||
homeDirectory = homeDir;
|
homeDirectory = homeDir;
|
||||||
|
@ -87,10 +86,7 @@ in rec {
|
||||||
lean4
|
lean4
|
||||||
slippi-netplay
|
slippi-netplay
|
||||||
xwallpaper
|
xwallpaper
|
||||||
blueberry
|
networkmanagerapplet
|
||||||
pulseaudio
|
|
||||||
brightnessctl
|
|
||||||
maim
|
|
||||||
];
|
];
|
||||||
file.".config/berry/autostart" = {
|
file.".config/berry/autostart" = {
|
||||||
source = ./berry_config;
|
source = ./berry_config;
|
||||||
|
@ -475,12 +471,10 @@ in rec {
|
||||||
|
|
||||||
sxhkd = {
|
sxhkd = {
|
||||||
enable = true;
|
enable = true;
|
||||||
package = pkgs.sxhkd;
|
|
||||||
extraOptions = [ "-m 1" ];
|
|
||||||
keybindings = {
|
keybindings = {
|
||||||
"super + Return" = "alacritty";
|
"super + Return" = "alacritty";
|
||||||
"super + BackSpace" = "firefox";
|
"super + BackSpace" = "firefox";
|
||||||
"super + r" = "rofi -show drun";
|
"super + r" = "rofi -show run";
|
||||||
"super + p" = "cpypsk";
|
"super + p" = "cpypsk";
|
||||||
"super + l" = "betterlockscreen -l";
|
"super + l" = "betterlockscreen -l";
|
||||||
"super + Left" = "berryc snap_left";
|
"super + Left" = "berryc snap_left";
|
||||||
|
@ -489,15 +483,15 @@ in rec {
|
||||||
"super + {1,2,3,4}" = "berryc switch_workspace {0,1,2,3}";
|
"super + {1,2,3,4}" = "berryc switch_workspace {0,1,2,3}";
|
||||||
"super + shift + {1,2,3,4}" = "berryc send_to_workspace {0,1,2,3}";
|
"super + shift + {1,2,3,4}" = "berryc send_to_workspace {0,1,2,3}";
|
||||||
"super + f" = "berryc fullscreen_state";
|
"super + f" = "berryc fullscreen_state";
|
||||||
|
"super + {h,j,k,l}" = "berryc cardinal_focus {2,3,1,0}";
|
||||||
"alt + Tab" = "berryc cycle_focus";
|
"alt + Tab" = "berryc cycle_focus";
|
||||||
"~button1" = "berryc pointer_focus";
|
"~button1" = "berryc pointer_focus";
|
||||||
"~Escape" = "dunstctl close-all";
|
"Print" = "${pkgs.maim}/bin/maim -s ~/img/scrot$(date +%s).png";
|
||||||
"Print" = "maim -s ~/img/scrot$(date +%s).png";
|
"XF86AudioMute" = "${pkgs.pulseaudio}/bin/pactl set-sink-mute @DEFAULT_SINK@ toggle";
|
||||||
"XF86AudioMute" = "${vol} mute";
|
"XF86AudioRaiseVolume" = "${pkgs.pulseaudio}/bin/pactl set-sink-volume @DEFAULT_SINK@ +5%";
|
||||||
"XF86AudioRaiseVolume" = "${vol} +5%";
|
"XF86AudioLowerVolume" = "${pkgs.pulseaudio}/bin/pactl set-sink-volume @DEFAULT_SINK@ -5%";
|
||||||
"XF86AudioLowerVolume" = "${vol} -5%";
|
"XF86MonBrightnessUp" = "${pkgs.brightnessctl}/bin/brightnessctl set 5%+";
|
||||||
"XF86MonBrightnessUp" = "${light} 5%+";
|
"XF86MonBrightnessDown" = "${pkgs.brightnessctl}/bin/brightnessctl set 5%-";
|
||||||
"XF86MonBrightnessDown" = "${light} 5%-";
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -514,71 +508,10 @@ in rec {
|
||||||
|
|
||||||
dunst = {
|
dunst = {
|
||||||
enable = true;
|
enable = true;
|
||||||
settings = {
|
|
||||||
volume = {
|
|
||||||
appname = "changeVolume";
|
|
||||||
history_ignore = "yes";
|
|
||||||
};
|
|
||||||
light = {
|
|
||||||
appname = "changeLight";
|
|
||||||
history_ignore = "yes";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
network-manager-applet = {
|
|
||||||
enable = true;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
betterlockscreen = {
|
betterlockscreen = {
|
||||||
enable = true;
|
enable = true;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
systemd.user= {
|
|
||||||
timers = {
|
|
||||||
battery-check = {
|
|
||||||
Unit.Description = "Warn at low battery levels";
|
|
||||||
Timer = {
|
|
||||||
OnBootSec = "1min";
|
|
||||||
OnUnitActiveSec = "30s";
|
|
||||||
Unit = "battery-check.service";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
services = {
|
|
||||||
battery-check = {
|
|
||||||
Unit.Description = "Warn at low battery levels";
|
|
||||||
Service = let batMon = pkgs.writeShellScript "botMon" ''
|
|
||||||
PATH="$PATH:${pkgs.lib.makeBinPath [
|
|
||||||
pkgs.acpi
|
|
||||||
pkgs.dunst
|
|
||||||
pkgs.gnugrep
|
|
||||||
pkgs.gawk
|
|
||||||
pkgs.systemd
|
|
||||||
]}"
|
|
||||||
acpi -b | grep "Battery 0" | awk -F'[,:%]' '{print $2, $3}' | {
|
|
||||||
read -r status capacity
|
|
||||||
|
|
||||||
if [ "$status" = Discharging -a "$capacity" -lt 2 ]; then
|
|
||||||
dunstify -u critical -a batMon \
|
|
||||||
-h string:x-dunst-stack-tag:batMon \
|
|
||||||
-h int:value:"$capacity" "Battery Critical: ''${capacity}%
|
|
||||||
Hibernating"
|
|
||||||
sleep 5
|
|
||||||
systemctl hibernate
|
|
||||||
elif [ "$status" = Discharging -a "$capacity" -lt 5 ]; then
|
|
||||||
dunstify -u critical -a batMon \
|
|
||||||
-h string:x-dunst-stack-tag:batMon \
|
|
||||||
-h int:value:"$capacity" "Battery Critical: ''${capacity}%"
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
'';
|
|
||||||
in {
|
|
||||||
ExecStart = "${batMon}";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
23
home/vol.sh
23
home/vol.sh
|
@ -1,23 +0,0 @@
|
||||||
#!/usr/bin/env bash
|
|
||||||
|
|
||||||
msgTag="voldunst"
|
|
||||||
|
|
||||||
case "$1" in
|
|
||||||
mute)
|
|
||||||
pactl set-sink-mute @DEFAULT_SINK@ toggle > /dev/null
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
pactl set-sink-volume @DEFAULT_SINK@ "$1" > /dev/null
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
volume="$(pactl get-sink-volume @DEFAULT_SINK@ | head -1 | awk '{ print $5 }')"
|
|
||||||
mute="$(pactl get-sink-mute @DEFAULT_SINK@ | cut -d' ' -f2)"
|
|
||||||
if [[ $volume == "0%" || "$mute" == "yes" ]]; then
|
|
||||||
dunstify -a "changeVolume" -u low \
|
|
||||||
-h string:x-dunst-stack-tag:$msgTag "Volume muted"
|
|
||||||
else
|
|
||||||
dunstify -a "changeVolume" -u low \
|
|
||||||
-h string:x-dunst-stack-tag:$msgTag \
|
|
||||||
-h int:value:"$volume" "Volume: ${volume}"
|
|
||||||
fi
|
|
13
home/xinitrc
13
home/xinitrc
|
@ -10,12 +10,9 @@ if command -v dbus-update-activation-environment >/dev/null 2>&1; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
xwallpaper --zoom "$HOME"/img/wallpaper
|
xwallpaper --zoom "$HOME"/img/wallpaper
|
||||||
|
nm-applet &
|
||||||
systemctl stop --user sxhkd.scope
|
polybar &
|
||||||
systemd-cat -t sxhkd systemd-run --user --scope --property=OOMPolicy=continue -u sxhkd sxhkd -m 1 &
|
sxhkd &
|
||||||
systemctl restart --user dunst
|
picom &
|
||||||
systemctl restart --user picom
|
dusnt &
|
||||||
systemctl restart --user polybar
|
|
||||||
systemctl restart --user network-manager-applet
|
|
||||||
systemctl restart --user battery-check.timer
|
|
||||||
exec berry
|
exec berry
|
||||||
|
|
Loading…
Reference in New Issue
Block a user