2024-07-12 01:40:59 +03:00
|
|
|
{ config, pkgs, ... }:
|
2024-07-12 01:46:57 +03:00
|
|
|
let
|
2024-12-10 20:20:45 +02:00
|
|
|
alacritty-conf = "${
|
|
|
|
(import ./alacritty.nix {
|
|
|
|
inherit config;
|
|
|
|
inherit pkgs;
|
|
|
|
})
|
|
|
|
}";
|
2024-07-12 01:46:57 +03:00
|
|
|
i3status-conf = "${pkgs.writeText "i3status-conf" ''
|
|
|
|
# It is important that this file is edited as UTF-8.
|
|
|
|
# The following line should contain a sharp s:
|
|
|
|
# ß
|
|
|
|
# If the above line is not correctly displayed, fix your editor first!
|
|
|
|
|
|
|
|
general {
|
2024-07-12 16:47:46 +03:00
|
|
|
output_format = "i3bar"
|
|
|
|
colors = true
|
|
|
|
interval = 1
|
|
|
|
color_good = "#2AA198"
|
|
|
|
color_bad = "#586E75"
|
|
|
|
color_degraded = "#DC322F"
|
2024-07-12 01:46:57 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
order += "battery all"
|
|
|
|
order += "cpu_usage"
|
|
|
|
order += "memory"
|
2025-01-11 02:01:41 +02:00
|
|
|
order += "ipv6"
|
2024-07-12 01:46:57 +03:00
|
|
|
order += "ethernet _first_"
|
|
|
|
order += "wireless _first_"
|
|
|
|
order += "disk /"
|
|
|
|
order += "tztime local"
|
|
|
|
order += "tztime helsinki"
|
|
|
|
|
2024-07-12 14:58:56 +03:00
|
|
|
battery all {
|
2024-07-12 16:47:46 +03:00
|
|
|
format = " %status %percentage (%remaining @ %consumption) "
|
|
|
|
format_down = ""
|
|
|
|
last_full_capacity = true
|
|
|
|
integer_battery_capacity = true
|
|
|
|
low_threshold = 30
|
|
|
|
threshold_type = time
|
2024-07-12 14:58:56 +03:00
|
|
|
}
|
|
|
|
|
2024-07-12 01:46:57 +03:00
|
|
|
cpu_usage {
|
2024-07-12 16:47:46 +03:00
|
|
|
format = " CPU %usage "
|
2024-07-12 01:46:57 +03:00
|
|
|
}
|
|
|
|
|
2024-07-12 14:58:56 +03:00
|
|
|
memory {
|
2024-07-12 16:47:46 +03:00
|
|
|
format = " RAM %used / %total "
|
|
|
|
threshold_degraded = "10%"
|
2024-07-12 01:46:57 +03:00
|
|
|
}
|
|
|
|
|
2025-01-11 02:01:41 +02:00
|
|
|
ipv6 {
|
|
|
|
format_up = " %iface: %ip "
|
|
|
|
format_down = " No IPv6 "
|
|
|
|
}
|
|
|
|
|
2024-07-12 01:46:57 +03:00
|
|
|
ethernet _first_ {
|
2024-07-12 16:47:46 +03:00
|
|
|
format_up = " LAN: %ip "
|
|
|
|
format_down = " No LAN "
|
2024-07-12 01:46:57 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
wireless _first_ {
|
2024-07-12 16:47:46 +03:00
|
|
|
format_up = " %quality%essid: %ip "
|
2025-01-11 02:01:41 +02:00
|
|
|
format_down = " No WLAN "
|
2024-07-12 01:46:57 +03:00
|
|
|
}
|
|
|
|
|
2024-07-12 14:58:56 +03:00
|
|
|
disk "/" {
|
2024-07-12 16:47:46 +03:00
|
|
|
format = " ⛁ %avail "
|
2024-07-12 01:46:57 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
tztime local {
|
2024-07-12 17:38:29 +03:00
|
|
|
format = " %d.%m. %H:%M "
|
2024-07-12 01:46:57 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
tztime helsinki {
|
2024-07-12 16:47:46 +03:00
|
|
|
format = " (HEL %H:%M) "
|
|
|
|
timezone = "Europe/Helsinki"
|
|
|
|
hide_if_equals_localtime = true
|
2024-07-12 01:46:57 +03:00
|
|
|
}
|
|
|
|
''}";
|
|
|
|
in
|
2024-07-12 01:40:59 +03:00
|
|
|
pkgs.writeText "i3-conf" ''
|
|
|
|
# Set mod key (Mod1=<Alt>, Mod4=<Super>)
|
2024-07-28 22:01:07 +03:00
|
|
|
set $mod Mod1
|
|
|
|
set $secondary Mod4
|
2024-07-12 01:40:59 +03:00
|
|
|
|
|
|
|
|
|
|
|
|
2024-07-12 18:56:38 +03:00
|
|
|
exec --no-startup-id nm-applet --sm-disable
|
2025-05-27 21:43:24 +03:00
|
|
|
exec --no-startup-id bitwarden
|
2024-07-12 18:56:38 +03:00
|
|
|
for_window [window_type="notification"] floating enable
|
2024-07-12 01:40:59 +03:00
|
|
|
|
2024-07-12 18:56:38 +03:00
|
|
|
# Screen brightness controls
|
|
|
|
bindcode 232 exec --no-startup-id brightnessctl set 5%-
|
|
|
|
bindcode 233 exec --no-startup-id brightnessctl set 5%+
|
|
|
|
|
2024-12-10 20:20:45 +02:00
|
|
|
bindsym $mod+Return exec "alacritty --config-file ${alacritty-conf}"
|
2024-07-16 14:49:24 +03:00
|
|
|
bindsym $mod+d exec --no-startup-id "rofi -theme 'Arc-Dark' -show combi -combi-modes 'run' -modes combi"
|
2024-07-12 01:40:59 +03:00
|
|
|
|
2024-10-22 15:09:59 +03:00
|
|
|
bindsym $mod+Shift+p mode "$mode_system"
|
2024-10-22 15:39:46 +03:00
|
|
|
set $mode_system (l)ock, (s)uspend, (h)ibernate, (r)eboot, (S)hutdown
|
2024-10-22 15:09:59 +03:00
|
|
|
mode "$mode_system" {
|
2025-05-27 23:20:38 +03:00
|
|
|
bindsym l exec --no-startup-id i3lock, mode "default"
|
|
|
|
bindsym s exec --no-startup-id systemctl suspend, mode "default"
|
2024-10-22 15:09:59 +03:00
|
|
|
bindsym h exec --no-startup-id systemctl hibernate, mode "default"
|
|
|
|
bindsym r exec --no-startup-id systemctl reboot, mode "default"
|
2024-10-22 15:39:46 +03:00
|
|
|
bindsym Shift+s exec --no-startup-id systemctl poweroff, mode "default"
|
2024-10-22 15:09:59 +03:00
|
|
|
bindsym Return mode "default"
|
|
|
|
bindsym Escape mode "default"
|
|
|
|
}
|
|
|
|
|
2024-07-12 01:40:59 +03:00
|
|
|
|
|
|
|
|
2024-07-12 18:56:38 +03:00
|
|
|
font xft:DejaVuSansMono-Book 14
|
|
|
|
default_border pixel 3
|
|
|
|
gaps inner 2
|
|
|
|
|
|
|
|
bar {
|
|
|
|
i3bar_command i3bar
|
|
|
|
status_command i3status -c ${i3status-conf}
|
|
|
|
|
|
|
|
## please set your primary output first. Example: 'xrandr --output eDP1 --primary'
|
|
|
|
tray_output primary
|
|
|
|
|
2024-07-31 10:57:49 +03:00
|
|
|
bindsym button4 nop
|
|
|
|
bindsym button5 nop
|
|
|
|
|
2024-07-12 18:56:38 +03:00
|
|
|
colors {
|
|
|
|
background #0f212f
|
|
|
|
statusline #d0d0d0
|
|
|
|
separator #d0d0d0
|
|
|
|
|
|
|
|
# border back. text
|
|
|
|
active_workspace #303030 #505050 #d0d0d0
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2024-07-12 01:40:59 +03:00
|
|
|
|
|
|
|
|
2024-07-12 18:56:38 +03:00
|
|
|
bindsym $mod+Shift+q kill
|
|
|
|
|
|
|
|
floating_modifier $mod
|
|
|
|
|
2024-07-12 18:40:14 +03:00
|
|
|
bindsym $mod+s split h
|
|
|
|
bindsym $mod+v split v
|
2024-07-12 01:40:59 +03:00
|
|
|
|
|
|
|
bindsym $mod+f fullscreen toggle
|
|
|
|
bindsym $mod+Shift+space floating toggle
|
|
|
|
bindsym $mod+space focus mode_toggle
|
|
|
|
|
|
|
|
bindsym $mod+Shift+c reload
|
|
|
|
bindsym $mod+Shift+r restart
|
|
|
|
|
2024-07-12 18:56:38 +03:00
|
|
|
|
|
|
|
|
|
|
|
bindsym $mod+h focus left
|
|
|
|
bindsym $mod+j focus down
|
|
|
|
bindsym $mod+k focus up
|
|
|
|
bindsym $mod+l focus right
|
|
|
|
|
|
|
|
bindsym $mod+Shift+h move left
|
|
|
|
bindsym $mod+Shift+j move down
|
|
|
|
bindsym $mod+Shift+k move up
|
|
|
|
bindsym $mod+Shift+l move right
|
|
|
|
|
2024-07-12 01:40:59 +03:00
|
|
|
bindsym $mod+r mode "resize"
|
|
|
|
mode "resize" {
|
2024-07-12 18:40:14 +03:00
|
|
|
bindsym h resize shrink width 5 px or 5 ppt
|
|
|
|
bindsym j resize grow height 5 px or 5 ppt
|
|
|
|
bindsym k resize shrink height 5 px or 5 ppt
|
|
|
|
bindsym l resize grow width 5 px or 5 ppt
|
2024-07-12 01:40:59 +03:00
|
|
|
|
2024-07-12 18:40:14 +03:00
|
|
|
bindsym Return mode "default"
|
|
|
|
bindsym Escape mode "default"
|
2024-07-12 01:40:59 +03:00
|
|
|
}
|
|
|
|
|
2024-07-12 18:40:14 +03:00
|
|
|
|
|
|
|
|
2024-07-17 10:58:25 +03:00
|
|
|
workspace 1 output primary
|
|
|
|
workspace 2 output primary
|
|
|
|
workspace 3 output primary
|
|
|
|
workspace 4 output primary
|
|
|
|
workspace 5 output primary
|
|
|
|
workspace 6 output primary
|
|
|
|
workspace 7 output primary
|
|
|
|
workspace 8 output primary
|
|
|
|
workspace 9 output primary
|
|
|
|
workspace 10 output primary
|
2024-12-06 19:25:57 +02:00
|
|
|
workspace 11 output eDP primary
|
|
|
|
workspace 12 output eDP primary
|
|
|
|
workspace 13 output eDP primary
|
|
|
|
workspace 14 output eDP primary
|
|
|
|
workspace 15 output eDP primary
|
|
|
|
workspace 16 output eDP primary
|
|
|
|
workspace 17 output eDP primary
|
|
|
|
workspace 18 output eDP primary
|
2024-07-17 10:58:25 +03:00
|
|
|
|
2024-07-12 18:40:14 +03:00
|
|
|
# switch to workspace
|
|
|
|
bindsym $mod+1 workspace 1
|
|
|
|
bindsym $mod+2 workspace 2
|
|
|
|
bindsym $mod+3 workspace 3
|
|
|
|
bindsym $mod+4 workspace 4
|
|
|
|
bindsym $mod+5 workspace 5
|
|
|
|
bindsym $mod+6 workspace 6
|
|
|
|
bindsym $mod+7 workspace 7
|
|
|
|
bindsym $mod+8 workspace 8
|
|
|
|
bindsym $mod+9 workspace 9
|
|
|
|
bindsym $mod+0 workspace 10
|
2024-07-28 22:01:07 +03:00
|
|
|
bindsym $mod+$secondary+1 workspace 11
|
|
|
|
bindsym $mod+$secondary+2 workspace 12
|
|
|
|
bindsym $mod+$secondary+3 workspace 13
|
|
|
|
bindsym $mod+$secondary+4 workspace 14
|
|
|
|
bindsym $mod+$secondary+5 workspace 15
|
|
|
|
bindsym $mod+$secondary+6 workspace 16
|
|
|
|
bindsym $mod+$secondary+7 workspace 17
|
|
|
|
bindsym $mod+$secondary+8 workspace 18
|
|
|
|
bindsym $mod+$secondary+9 workspace 19
|
|
|
|
bindsym $mod+$secondary+0 workspace 20
|
2024-07-12 18:40:14 +03:00
|
|
|
|
|
|
|
# Move focused container to workspace
|
|
|
|
bindsym $mod+Ctrl+1 move container to workspace 1
|
|
|
|
bindsym $mod+Ctrl+2 move container to workspace 2
|
|
|
|
bindsym $mod+Ctrl+3 move container to workspace 3
|
|
|
|
bindsym $mod+Ctrl+4 move container to workspace 4
|
|
|
|
bindsym $mod+Ctrl+5 move container to workspace 5
|
|
|
|
bindsym $mod+Ctrl+6 move container to workspace 6
|
|
|
|
bindsym $mod+Ctrl+7 move container to workspace 7
|
|
|
|
bindsym $mod+Ctrl+8 move container to workspace 8
|
|
|
|
bindsym $mod+Ctrl+9 move container to workspace 9
|
|
|
|
bindsym $mod+Ctrl+0 move container to workspace 10
|
2024-07-28 22:01:07 +03:00
|
|
|
bindsym $mod+$secondary+Ctrl+1 move container to workspace 11
|
|
|
|
bindsym $mod+$secondary+Ctrl+2 move container to workspace 12
|
|
|
|
bindsym $mod+$secondary+Ctrl+3 move container to workspace 13
|
|
|
|
bindsym $mod+$secondary+Ctrl+4 move container to workspace 14
|
|
|
|
bindsym $mod+$secondary+Ctrl+5 move container to workspace 15
|
|
|
|
bindsym $mod+$secondary+Ctrl+6 move container to workspace 16
|
|
|
|
bindsym $mod+$secondary+Ctrl+7 move container to workspace 17
|
|
|
|
bindsym $mod+$secondary+Ctrl+8 move container to workspace 18
|
|
|
|
bindsym $mod+$secondary+Ctrl+9 move container to workspace 19
|
|
|
|
bindsym $mod+$secondary+Ctrl+0 move container to workspace 20
|
2024-07-12 18:40:14 +03:00
|
|
|
|
|
|
|
# Move to workspace with focused container
|
|
|
|
bindsym $mod+Shift+1 move container to workspace 1; workspace 1
|
|
|
|
bindsym $mod+Shift+2 move container to workspace 2; workspace 2
|
|
|
|
bindsym $mod+Shift+3 move container to workspace 3; workspace 3
|
|
|
|
bindsym $mod+Shift+4 move container to workspace 4; workspace 4
|
|
|
|
bindsym $mod+Shift+5 move container to workspace 5; workspace 5
|
|
|
|
bindsym $mod+Shift+6 move container to workspace 6; workspace 6
|
|
|
|
bindsym $mod+Shift+7 move container to workspace 7; workspace 7
|
|
|
|
bindsym $mod+Shift+8 move container to workspace 8; workspace 8
|
|
|
|
bindsym $mod+Shift+9 move container to workspace 9; workspace 9
|
|
|
|
bindsym $mod+Shift+0 move container to workspace 10; workspace 10
|
2024-07-28 22:01:07 +03:00
|
|
|
bindsym $mod+$secondary+Shift+1 move container to workspace 11; workspace 11
|
|
|
|
bindsym $mod+$secondary+Shift+2 move container to workspace 12; workspace 12
|
|
|
|
bindsym $mod+$secondary+Shift+3 move container to workspace 13; workspace 13
|
|
|
|
bindsym $mod+$secondary+Shift+4 move container to workspace 14; workspace 14
|
|
|
|
bindsym $mod+$secondary+Shift+5 move container to workspace 15; workspace 15
|
|
|
|
bindsym $mod+$secondary+Shift+6 move container to workspace 16; workspace 16
|
|
|
|
bindsym $mod+$secondary+Shift+7 move container to workspace 17; workspace 17
|
|
|
|
bindsym $mod+$secondary+Shift+8 move container to workspace 18; workspace 18
|
|
|
|
bindsym $mod+$secondary+Shift+9 move container to workspace 19; workspace 19
|
|
|
|
bindsym $mod+$secondary+Shift+0 move container to workspace 20; workspace 20
|
2024-07-12 01:40:59 +03:00
|
|
|
''
|