niri: window rules; use hyprlock; fix keymaps

This commit is contained in:
Oleksandr Smirnov 2025-06-15 20:15:31 +03:00
parent 9860b3c944
commit d9ffea63f1
No known key found for this signature in database

View file

@ -18,7 +18,6 @@ environment {
// https://github.com/YaLTeR/niri/wiki/Configuration:-Input
input {
keyboard {
numlock
xkb {
layout "us,ua"
options "grp:win_space_toggle,compose:ralt,ctrl:nocaps"
@ -30,7 +29,6 @@ input {
// dwtp
// drag false
// drag-lock
// natural-scroll
accel-speed 0.1
accel-profile "adaptive"
scroll-method "two-finger"
@ -135,8 +133,9 @@ window-rule {
}
window-rule {
match app-id="org.gnome.Solanum"
exclude app-id="zen"
match app-id="org.gnome.Solanum";
default-floating-position relative-to="top-left" x=10 y=10
open-focused true
open-on-workspace "laptop"
}
@ -173,7 +172,7 @@ window-rule {
}
window-rule {
match app-id="org.keepassxc.KeePassXC"
match app-id="KeePassXC"
match app-id="obsidian"
match app-id="org.telegram.desktop"
block-out-from "screen-capture"
@ -185,15 +184,16 @@ binds {
Mod+Return { spawn "kitty"; }
Mod+Shift+Return { spawn "wofi" "--show" "drun"; }
Mod+Shift+Escape { spawn "~/bin/wofi-power-menu" "niri";}
Super+Alt+L { spawn "swaylock"; } // TODO: change to hyprlock
Super+Alt+L { spawn "hyprlock"; }
// programs {{{
Mod+Shift+a { spawn "anki"; }
Mod+Shift+d { spawn "obsidian"; }
// Mod+Shift+f { spawn "newsflash"; } // TODO: fix conflict
Mod+Shift+f { spawn "newsflash"; }
Mod+Shift+s { spawn "spotify"; }
Mod+Shift+t { spawn "telegram-desktop"; }
Mod+Shift+w { spawn "zen-browser"; }
Mod+Shift+r { spawn "solanum"; }
// }}}
// func keys {{{
// audio
@ -203,7 +203,7 @@ binds {
XF86AudioMicMute allow-when-locked=true { spawn "wpctl" "set-mute" "@DEFAULT_AUDIO_SOURCE@" "toggle"; }
XF86AudioPlay allow-when-locked=true { spawn "playerctl" "play-pause"; }
XF86AudioNext allow-when-locked=true { spawn "playerctl" "next"; }
XF86AudioPrev allow-when-locked=true { spawn "playerctl" "prev"; }
XF86AudioPrev allow-when-locked=true { spawn "playerctl" "previous"; }
// brighthness
XF86MonBrightnessUp allow-when-locked=true { spawn "brightnessctl" "set" "+5%"; }
XF86MonBrightnessDown allow-when-locked=true { spawn "brightnessctl" "set" "5%-"; }
@ -253,8 +253,8 @@ binds {
Mod+Shift+4 { move-column-to-workspace 4; }
Mod+Shift+5 { move-column-to-workspace 5; }
Mod+WheelScrollDown cooldown-ms=150 { focus-workspace-down; }
Mod+WheelScrollUp cooldown-ms=150 { focus-workspace-up; }
Mod+WheelScrollDown cooldown-ms=150 { focus-workspace-down; }
Mod+WheelScrollUp cooldown-ms=150 { focus-workspace-up; }
// }}}
// }}}
}