Add Kanshi, Hyprland, remove Niri

This commit is contained in:
Bun 2025-05-04 22:54:21 -04:00
parent 4e90ea2e1c
commit 6feca365ff
26 changed files with 430 additions and 461 deletions

View file

@ -5,7 +5,6 @@
./hotkeys
./inputs
./outputs
./programs
./rules
./theme
];

View file

@ -17,7 +17,7 @@
# Virtual machines
"${primeMod}+F4" = ''exec virt-manager | notify-send "Virtual Machines"'';
"${primeMod}+F5" = ''exec looking-glass-client input:rawMouse=yes | notify-send "Looking Glass"'';
"${primeMod}+F5" = ''exec looking-glass-client | notify-send "Looking Glass"'';
# Prime + key
"${primeMod}+s" = ''exec rofi -show run -p Command'';
@ -34,7 +34,6 @@
"${primeMod}+Shift+Return" = ''exec foot ranger'';
# Prime + ctrl + key
"${primeMod}+Ctrl+x" = ''exec prop-sway'';
"${primeMod}+Ctrl+s" = ''exec rofiscratch'';
"${primeMod}+Ctrl+c" = ''exec wlpicker && notify-send "Color copied to clipboard"'';
@ -45,7 +44,7 @@
"${secMod}+k" = ''exec wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%+'';
"${secMod}+m" = ''exec wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle'';
# MPD
# MPRIS
"${primeMod}+Backslash" = ''exec playerctl -p firefox play-pause'';
"${primeMod}+Shift+Backslash" = ''exec playerctl -p mpd play-pause'';
"${secMod}+Shift+h" = ''exec playerctl -p mpd previous'';

View file

@ -41,30 +41,5 @@
(assign "${config.displays.d2}" workspaces2) ++
(assign "${config.displays.d3}" workspaces3) ++
(assign "${config.displays.d4}" workspaces4);
output = {
${config.displays.d1} = {
pos = "3840 405";
mode = "1920x1080@143.980Hz";
max_render_time = "3";
allow_tearing = "yes";
};
${config.displays.d2} = {
pos = "1920 405";
mode = "1920x1080@60Hz";
max_render_time = "3";
};
${config.displays.d3} = {
pos = "5760 0";
mode = "1680x1050@59.883Hz";
transform = "270";
max_render_time = "3";
};
${config.displays.d4} = {
pos = "0 405";
mode = "1920x1080@60Hz";
max_render_time = "3";
};
};
};
}

View file

@ -1,4 +0,0 @@
{ pkgs, ... }:
{
imports = [ ./prop-sway ];
}

View file

@ -1,13 +0,0 @@
{ config, lib, pkgs, ... }:
{
home.packages = with pkgs; lib.mkIf config.wayland.windowManager.sway.enable [
(pkgs.writeScriptBin "prop-sway" ''
selected_window=$(swaymsg -t get_tree | jq -r '.. | select(.pid? and .visible?) | "\(.rect.x),\(.rect.y) \(.rect.width)x\(.rect.height)"' | ${pkgs.slurp}/bin/slurp -r -c ${config.look.colors.prime} -B 00000066 -b 00000000)
if [ -n "$selected_window" ]; then
app_id=$(swaymsg -t get_tree | jq -r '.. | select(.pid? and .visible?) | select("\(.rect.x),\(.rect.y) \(.rect.width)x\(.rect.height)" == "'"$selected_window"'") | .app_id')
system=$(sed 's/xdg_shell/Wayland/g; s/xwayland/Xorg/g' < <(swaymsg -t get_tree | jq -r '.. | select(.pid? and .visible?) | select("\(.rect.x),\(.rect.y) \(.rect.width)x\(.rect.height)" == "'"$selected_window"'") | .shell'))
notify-send "$(echo -e "Window's app_id: $app_id\nWindow System: $system")"
fi
'')
];
}