adyya-flake/sway.mod.nix

105 lines
2.5 KiB
Nix

{
personal.modules = [
(
{ pkgs, ... }:
{
programs.sway = {
enable = true;
package = pkgs.swayfx;
};
environment.systemPackages = with pkgs; [
swayrbar
slurp
grim
rofi-wayland
swaybg
wl-clipboard
];
}
)
];
personal.home_modules = [
(
{ lib, pkgs, ... }:
wayland.windowManager.sway.config {
modifier = "Mod4";
fonts = {
names = [ "pango" ];
style = "monospace";
size = 8.0;
};
terminal = "$\{pkgs.terminator}/bin/terminator";
keybindings =
let
mod = wayland.windowManager.sway.config.modifier;
term = wayland.windowManager.sway.config.terminal;
in
lib.mkOptionDefault {
"${mod}+Return" = "exec ${term}"; # opens a terminal window
"${mod}+Shift+q" = "kill"; # kills the active window
"${mod}+s" = ''exec --no-startup-id rofi -run-command "/bin/sh -i -c '{cmd}'" -show combi'';
"${mod}+Tab" = "exec --no-startup-id rofi -show window";
};
assigns = {
"1:" = [ { title = "^Signal$|Discord$"; } ];
"2:main" = [ ];
"3:browsing" = [ { title = "Librewolf$"; } ];
"4:misc" = [ ];
"5:5" = [ ];
"6:6" = [ ];
"7:7" = [ ];
"8:8" = [ ];
"9:9" = [ ];
"0:audio" = [ { title = "pwvucontrol$|noisetorch$"; } ];
};
bars = [
{
statusCommand = "\${pkgs.swayrbar}/bin/swayrbar";
position = "bottom";
trayOutput = "primary";
separatorSymbol = "·";
workspaceButtons = true;
workspaceNumbers = false;
colors = {
};
}
];
output = {
DP-3 = {
mode = "3440x1440@144.000Hz";
};
};
input = {
"10429:2335:UGTABLET_11.6_inch_PenDisplay" = {
map_to_output = "UGD Artist 12 pro 0x19201012";
};
"type:keyboard" = {
xkb_layout = [
"us(colemak_dh)"
"us"
# "rulemak"
];
xkb_options = "grp:rctrl_toggle";
};
};
gaps = {
smartGaps = true;
inner = 8.0;
outer = 2.0;
};
workspaceAutoBackAndForth = true;
workspaceLayout = "tabbed";
}
)
];
}