Modified polybar
This commit is contained in:
@@ -17,6 +17,8 @@ let
|
||||
};
|
||||
});
|
||||
|
||||
system_mode = "System (l) lock, (e) logout, (s) suspend, (h) hibernate, (r) reboot, (Shift+s) shutdown";
|
||||
|
||||
in {
|
||||
|
||||
options.samfelag.modules.desktop.i3 = {
|
||||
@@ -44,6 +46,8 @@ in {
|
||||
|
||||
xsession.windowManager.i3 = {
|
||||
enable = true;
|
||||
package = pkgs.i3-gaps;
|
||||
|
||||
config = {
|
||||
modifier = mod;
|
||||
|
||||
@@ -57,11 +61,43 @@ in {
|
||||
|
||||
bars = [ ];
|
||||
|
||||
window = {
|
||||
border = 1;
|
||||
titlebar = false;
|
||||
};
|
||||
|
||||
# gaps = {
|
||||
# inner = 10;
|
||||
# outer = 5;
|
||||
# };
|
||||
|
||||
startup = [
|
||||
{ command = "i3-msg workspace 1"; }
|
||||
{ command = "systemctl --user restart polybar"; always = true; notification = false; }
|
||||
];
|
||||
|
||||
modes = {
|
||||
"resize" = {
|
||||
"h" = "resize shrink width 10 px or 10 ppt";
|
||||
"j" = "resize grow height 10 px or 10 ppt";
|
||||
"k" = "resize shrink height 10 px or 10 ppt";
|
||||
"l" = "resize grow width 10 px or 10 ppt";
|
||||
|
||||
"Left" = "resize shrink width 10 px or 10 ppt";
|
||||
"Down" = "resize grow height 10 px or 10 ppt";
|
||||
"Up" = "resize shrink height 10 px or 10 ppt";
|
||||
"Right" = "resize grow width 10 px or 10 ppt";
|
||||
|
||||
"Return" = "mode \"default\"";
|
||||
"Escape" = "mode \"default\"";
|
||||
};
|
||||
|
||||
"${system_mode}" = {
|
||||
"Return" = "mode \"default\"";
|
||||
"Escape" = "mode \"default\"";
|
||||
};
|
||||
};
|
||||
|
||||
keybindings = {
|
||||
"${mod}+q" = "kill";
|
||||
|
||||
@@ -107,6 +143,26 @@ in {
|
||||
"${mod}+Shift+c" = "reload";
|
||||
"${mod}+Shift+r" = "restart";
|
||||
|
||||
# - Modes ------------------------------
|
||||
"${mod}+r" = "mode \"resize\"";
|
||||
"${mod}+End" = "mode \"${system_mode}\"";
|
||||
|
||||
# - Media ------------------------------
|
||||
|
||||
# Pulse Audio controls
|
||||
"XF86AudioRaiseVolume" = "exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +5%";
|
||||
"XF86AudioLowerVolume" = "exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -5%";
|
||||
"Shift+XF86AudioRaiseVolume" = "exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +1%";
|
||||
"Shift+XF86AudioLowerVolume" = "exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -1%";
|
||||
"XF86AudioMute" = "exec --no-startup-id pactl set-sink-mute @DEFAULT_SINK@ toggle";
|
||||
|
||||
# Media player controls
|
||||
"XF86AudioPlay" = "exec playerctl play-pause";
|
||||
"XF86AudioPause" = "exec playerctl play-pause";
|
||||
"XF86AudioNext" = "exec playerctl next";
|
||||
"XF86AudioPrev" = "exec playerctl previous";
|
||||
"XF86AudioStop" = "exec playerctl stop";
|
||||
|
||||
# - Workspaces -------------------------
|
||||
"${mod}+1" = "workspace 1";
|
||||
"${mod}+2" = "workspace 2";
|
||||
|
||||
Reference in New Issue
Block a user