Hyprland stuff
This commit is contained in:
parent
46cc02538f
commit
f141a0ee04
6 changed files with 125 additions and 36 deletions
|
@ -12,10 +12,17 @@
|
||||||
|
|
||||||
wayland.windowManager.hyprland = {
|
wayland.windowManager.hyprland = {
|
||||||
settings = {
|
settings = {
|
||||||
|
env = [
|
||||||
|
"EWW_BAR_MON,1"
|
||||||
|
];
|
||||||
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
|
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
|
||||||
monitor = [
|
monitor = [
|
||||||
"DP-3,3840x2160@120,0x0,1"
|
"DP-3,3840x2160@120,0x0,1"
|
||||||
];
|
];
|
||||||
|
input = {
|
||||||
|
force_no_accel = true;
|
||||||
|
sensitivity = 1; # -1.0 - 1.0, 0 means no modification.
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -29,6 +29,8 @@ $rosewater: #f5e0dc;
|
||||||
all: unset;
|
all: unset;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.bar0,
|
||||||
|
.bar1,
|
||||||
.bar {
|
.bar {
|
||||||
background-color: $base;
|
background-color: $base;
|
||||||
color: $text;
|
color: $text;
|
||||||
|
@ -64,6 +66,8 @@ $rosewater: #f5e0dc;
|
||||||
border-radius: 10px;
|
border-radius: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.bar0>*,
|
||||||
|
.bar1>*,
|
||||||
.bar>* {
|
.bar>* {
|
||||||
padding-left: 10px;
|
padding-left: 10px;
|
||||||
padding-right: 10px;
|
padding-right: 10px;
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
(box)
|
(box)
|
||||||
(music)))
|
(music)))
|
||||||
|
|
||||||
(defwindow bar
|
(defwindow bar0
|
||||||
:monitor 0
|
:monitor 0
|
||||||
:stacking "fg"
|
:stacking "fg"
|
||||||
:exclusive true
|
:exclusive true
|
||||||
|
@ -17,6 +17,19 @@
|
||||||
:anchor "bottom center")
|
:anchor "bottom center")
|
||||||
(bar))
|
(bar))
|
||||||
|
|
||||||
|
(defwindow bar1
|
||||||
|
:monitor 1
|
||||||
|
:stacking "fg"
|
||||||
|
:exclusive true
|
||||||
|
:geometry
|
||||||
|
(geometry
|
||||||
|
:x "0%"
|
||||||
|
:y "0%"
|
||||||
|
:width "100%"
|
||||||
|
:height "31px"
|
||||||
|
:anchor "bottom center")
|
||||||
|
(bar))
|
||||||
|
|
||||||
(defwidget sidestuff []
|
(defwidget sidestuff []
|
||||||
(box :class "sidestuff" :orientation "h" :space-evenly false :halign "start" :spacing 20
|
(box :class "sidestuff" :orientation "h" :space-evenly false :halign "start" :spacing 20
|
||||||
time
|
time
|
||||||
|
@ -66,3 +79,6 @@
|
||||||
|
|
||||||
(defpoll brightness :interval "10s"
|
(defpoll brightness :interval "10s"
|
||||||
"echo $(((100 * $(brightnessctl get)) / $(brightnessctl max)))")
|
"echo $(((100 * $(brightnessctl get)) / $(brightnessctl max)))")
|
||||||
|
|
||||||
|
(defpoll monitor :interval "60s"
|
||||||
|
"echo $EWW_BAR_MON")
|
||||||
|
|
|
@ -2,6 +2,7 @@
|
||||||
outputs,
|
outputs,
|
||||||
colors,
|
colors,
|
||||||
config,
|
config,
|
||||||
|
lib,
|
||||||
# font,
|
# font,
|
||||||
...
|
...
|
||||||
}: {
|
}: {
|
||||||
|
@ -30,14 +31,39 @@
|
||||||
"hyprpaper"
|
"hyprpaper"
|
||||||
"mako"
|
"mako"
|
||||||
"/usr/lib/polkit-kde-authentication-agent-1"
|
"/usr/lib/polkit-kde-authentication-agent-1"
|
||||||
"eww daemon && eww open bar"
|
"eww daemon && eww open bar$EWW_BAR_MON"
|
||||||
"firefox & kitty --single-instance &"
|
"firefox & wezterm &"
|
||||||
|
(lib.concatStringsSep " " [
|
||||||
|
"swayidle -w"
|
||||||
|
"timeout 300 'notify-send \"Idling in 300 seconds\"'"
|
||||||
|
"resume 'notify-send \"Idling cancelled.\"'"
|
||||||
|
"timeout 480 'notify-send -u critical \"Idling in 120 seconds\"'"
|
||||||
|
"timeout 510 'notify-send -u critical \"Idling in 90 seconds\"'"
|
||||||
|
"timeout 540 'notify-send -u critical \"Idling in 60 seconds!\"'"
|
||||||
|
"timeout 570 'notify-send -u critical \"Idling in 30 seconds!\"'"
|
||||||
|
"timeout 590 'notify-send -u critical \"Idling in 10 seconds!\"'"
|
||||||
|
"timeout 591 'notify-send -u critical \"Idling in 9 seconds!\"'"
|
||||||
|
"timeout 592 'notify-send -u critical \"Idling in 8 seconds!\"'"
|
||||||
|
"timeout 593 'notify-send -u critical \"Idling in 7 seconds!\"'"
|
||||||
|
"timeout 594 'notify-send -u critical \"Idling in 6 seconds!\"'"
|
||||||
|
"timeout 595 'notify-send -u critical \"Idling in 5 seconds!\"'"
|
||||||
|
"timeout 596 'notify-send -u critical \"Idling in 4 seconds!\"'"
|
||||||
|
"timeout 597 'notify-send -u critical \"Idling in 3 seconds!\"'"
|
||||||
|
"timeout 598 'notify-send -u critical \"Idling in 2 seconds!\"'"
|
||||||
|
"timeout 599 'notify-send -u critical \"Idling in 1 second!\"'"
|
||||||
|
"timeout 600 'swaylock -f'"
|
||||||
|
"timeout 600 'hyprctl dispatch dpms off'"
|
||||||
|
"resume 'hyprctl dispatch dpms on'"
|
||||||
|
# "resume 'maybe-good-morning'"
|
||||||
|
"before-sleep 'swaylock -f'"
|
||||||
|
])
|
||||||
''swayidle -w timeout 600 'notify-send "Locking in 30 seconds..."' timeout 630 'swaylock -f' timeout 660 'hyprctl dispatch dpms off' resume 'hyprctl dispatch dpms on && maybe-good-morning' before-sleep 'swaylock -f'"''
|
''swayidle -w timeout 600 'notify-send "Locking in 30 seconds..."' timeout 630 'swaylock -f' timeout 660 'hyprctl dispatch dpms off' resume 'hyprctl dispatch dpms on && maybe-good-morning' before-sleep 'swaylock -f'"''
|
||||||
"dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP"
|
"dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP"
|
||||||
];
|
];
|
||||||
|
|
||||||
env = [
|
env = [
|
||||||
"XCURSOR_SIZE,24"
|
"XCURSOR_SIZE,24"
|
||||||
|
"EWW_BAR_MON,0"
|
||||||
];
|
];
|
||||||
|
|
||||||
input = {
|
input = {
|
||||||
|
@ -100,7 +126,7 @@
|
||||||
"$mainMod" = "SUPER";
|
"$mainMod" = "SUPER";
|
||||||
bind = [
|
bind = [
|
||||||
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
|
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
|
||||||
"$mainMod, return, exec, kitty --single-instance"
|
"$mainMod, return, exec, wezterm"
|
||||||
"$mainMod SHIFT, return, exec, kitty"
|
"$mainMod SHIFT, return, exec, kitty"
|
||||||
"$mainMod, U, exec, firefox"
|
"$mainMod, U, exec, firefox"
|
||||||
"$mainMod, space, exec, wofi --show drun"
|
"$mainMod, space, exec, wofi --show drun"
|
||||||
|
@ -223,9 +249,9 @@
|
||||||
# }
|
# }
|
||||||
|
|
||||||
# Example windowrule v1
|
# Example windowrule v1
|
||||||
# windowrule = float, ^(kitty)$
|
# windowrule = float, ^(kitty|firefox)$
|
||||||
# Example windowrule v2
|
# Example windowrule v2
|
||||||
# windowrulev2 = float,class:^(kitty)$,title:^(kitty)$
|
windowrulev2 = float,class:^.*(kitty|firefox|org.wezfurlong.wezterm).*$
|
||||||
# See https://wiki.hyprland.org/Configuring/Window-Rules/ for more
|
# See https://wiki.hyprland.org/Configuring/Window-Rules/ for more
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
|
@ -202,7 +202,7 @@
|
||||||
# bindsym $mod+shift+space exec wofi --show drun
|
# bindsym $mod+shift+space exec wofi --show drun
|
||||||
"${mod}+control+space" = "exec makoctl dismiss";
|
"${mod}+control+space" = "exec makoctl dismiss";
|
||||||
"${mod}+shift+space" = "exec makoctl invoke";
|
"${mod}+shift+space" = "exec makoctl invoke";
|
||||||
"${mod}+return" = "exec kitty --single-instance";
|
"${mod}+return" = "exec wezterm";
|
||||||
"${mod}+shift+return" = "exec floating-term";
|
"${mod}+shift+return" = "exec floating-term";
|
||||||
"${mod}+shift+alt+return" = "exec kitty";
|
"${mod}+shift+alt+return" = "exec kitty";
|
||||||
"${mod}+c" = "kill";
|
"${mod}+c" = "kill";
|
||||||
|
|
|
@ -36,46 +36,82 @@
|
||||||
-- config.window_frame.font = config.font
|
-- config.window_frame.font = config.font
|
||||||
-- config.window_frame.font_size = font_size
|
-- config.window_frame.font_size = font_size
|
||||||
|
|
||||||
|
function tab_title(tab_info)
|
||||||
|
local title = tab_info.tab_title
|
||||||
|
if title and #title > 0 then
|
||||||
|
return title
|
||||||
|
end
|
||||||
|
return tab_info.active_pane.title
|
||||||
|
end
|
||||||
|
|
||||||
|
wezterm.on('format-tab-title', function (tab, tabs, panes, config, hover, max_width)
|
||||||
|
local title = tab_title(tab)
|
||||||
|
return ' ' .. string.sub(title, 0, max_width - 2) .. ' '
|
||||||
|
end)
|
||||||
|
|
||||||
config.colors = {
|
config.colors = {
|
||||||
foreground = '${fg}',
|
foreground = '${fg}',
|
||||||
background = '${primary}',
|
background = '${bg}',
|
||||||
cursor_bg = '${text}',
|
cursor_bg = '${text}',
|
||||||
cursor_fg = '${bg}',
|
cursor_fg = '${bg}',
|
||||||
-- Specifies the border color of the cursor when the cursor style is set to Block,
|
cursor_border = '${text}',
|
||||||
-- or the color of the vertical or horizontal bar when the cursor style is set to
|
|
||||||
-- Bar or Underline.
|
|
||||||
cursor_border = '#52ad70',
|
|
||||||
|
|
||||||
-- the foreground color of selected text
|
selection_fg = '${bg}',
|
||||||
selection_fg = 'black',
|
selection_bg = '${yellow}',
|
||||||
-- the background color of selected text
|
|
||||||
selection_bg = '#fffacd',
|
|
||||||
|
|
||||||
-- The color of the scrollbar "thumb"; the portion that represents the current viewport
|
scrollbar_thumb = '${bg2}',
|
||||||
scrollbar_thumb = '#222222',
|
|
||||||
|
|
||||||
-- The color of the split lines between panes
|
split = '${bg5}',
|
||||||
split = '#444444',
|
|
||||||
|
|
||||||
ansi = {
|
ansi = {
|
||||||
'black',
|
'${colors.withHashPrefix."0"}',
|
||||||
'maroon',
|
'${colors.withHashPrefix."1"}',
|
||||||
'green',
|
'${colors.withHashPrefix."2"}',
|
||||||
'olive',
|
'${colors.withHashPrefix."3"}',
|
||||||
'navy',
|
'${colors.withHashPrefix."4"}',
|
||||||
'purple',
|
'${colors.withHashPrefix."5"}',
|
||||||
'teal',
|
'${colors.withHashPrefix."6"}',
|
||||||
'silver',
|
'${colors.withHashPrefix."7"}',
|
||||||
},
|
},
|
||||||
brights = {
|
brights = {
|
||||||
'grey',
|
'${colors.withHashPrefix."8"}',
|
||||||
'red',
|
'${colors.withHashPrefix."9"}',
|
||||||
'lime',
|
'${colors.withHashPrefix."10"}',
|
||||||
'yellow',
|
'${colors.withHashPrefix."11"}',
|
||||||
'blue',
|
'${colors.withHashPrefix."12"}',
|
||||||
'fuchsia',
|
'${colors.withHashPrefix."13"}',
|
||||||
'aqua',
|
'${colors.withHashPrefix."14"}',
|
||||||
'white',
|
'${colors.withHashPrefix."15"}',
|
||||||
|
},
|
||||||
|
|
||||||
|
tab_bar = {
|
||||||
|
background = '${bg3}',
|
||||||
|
|
||||||
|
active_tab = {
|
||||||
|
bg_color = '${primary}',
|
||||||
|
fg_color = '${bg}',
|
||||||
|
italic = false,
|
||||||
|
},
|
||||||
|
inactive_tab = {
|
||||||
|
bg_color = '${bg2}',
|
||||||
|
fg_color = '${fgdim}',
|
||||||
|
italic = false,
|
||||||
|
},
|
||||||
|
inactive_tab_hover = {
|
||||||
|
bg_color = '${bg3}',
|
||||||
|
fg_color = '${primary}',
|
||||||
|
italic = false,
|
||||||
|
},
|
||||||
|
new_tab = {
|
||||||
|
bg_color = '${bg2}',
|
||||||
|
fg_color = '${fgdim}',
|
||||||
|
italic = false,
|
||||||
|
},
|
||||||
|
new_tab_hover = {
|
||||||
|
bg_color = '${bg3}',
|
||||||
|
fg_color = '${primary}',
|
||||||
|
italic = false,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
-- Arbitrary colors of the palette in the range from 16 to 255
|
-- Arbitrary colors of the palette in the range from 16 to 255
|
||||||
|
|
Loading…
Reference in a new issue