forked from fabian/nix_config
configure sway (this is a huge rice)
This commit is contained in:
parent
4316165e9d
commit
5d1408254a
16 changed files with 381 additions and 799 deletions
|
@ -12,16 +12,9 @@ in {
|
|||
pkgs.wlr-randr
|
||||
];
|
||||
|
||||
programs = {
|
||||
waybar.enable = true;
|
||||
|
||||
wofi.enable = true;
|
||||
};
|
||||
|
||||
services = {
|
||||
swayidle = {
|
||||
enable = true;
|
||||
|
||||
timeouts = [
|
||||
{
|
||||
timeout = 600;
|
||||
|
@ -42,13 +35,32 @@ in {
|
|||
enable = true;
|
||||
|
||||
config = {
|
||||
output =
|
||||
lib.mapAttrs (k: v: {
|
||||
mode = "${toString v.width}x${toString v.height}@${v.rate}Hz";
|
||||
pos = "${toString v.posX} ${toString v.posY}";
|
||||
})
|
||||
cfg.monitors;
|
||||
|
||||
modifier = "Mod4";
|
||||
focus.followMouse = true;
|
||||
|
||||
input = {
|
||||
"*" = {
|
||||
xkb_layout = "us";
|
||||
xkb_variant = "altgr-intl";
|
||||
};
|
||||
};
|
||||
|
||||
fonts = {
|
||||
size = 11.0;
|
||||
names = ["DejaVu Sans Mono"];
|
||||
style = "Bold Semi-Condensed";
|
||||
names = ["JetBrains Mono"];
|
||||
style = "Regular";
|
||||
size = 8.0;
|
||||
};
|
||||
|
||||
gaps = {
|
||||
inner = 10;
|
||||
outer = -10;
|
||||
};
|
||||
|
||||
bars = singleton {
|
||||
|
@ -56,6 +68,23 @@ in {
|
|||
position = "top";
|
||||
};
|
||||
|
||||
window = {
|
||||
hideEdgeBorders = "both";
|
||||
titlebar = false;
|
||||
};
|
||||
|
||||
workspaceLayout = "tabbed";
|
||||
|
||||
colors = {
|
||||
focused = {
|
||||
background = "#222222";
|
||||
border = "#4c7899";
|
||||
childBorder = "#222222";
|
||||
indicator = "#292d2e";
|
||||
text = "#888888";
|
||||
};
|
||||
};
|
||||
|
||||
keybindings = let
|
||||
mod = config.wayland.windowManager.sway.config.modifier;
|
||||
wofi = config.programs.wofi.package;
|
||||
|
@ -66,26 +95,30 @@ in {
|
|||
"${mod}+a" = "focus parent";
|
||||
"${mod}+c" = "focus child";
|
||||
"${mod}+d" = "exec --no-startup-id ${getExe wofi} -S run";
|
||||
"${mod}+i" = "exec busctl --user call rs.wl-gammarelay / rs.wl.gammarelay ToggleInverted";
|
||||
"${mod}+o" = "exec ${getExe pkgs.gtklock} -d";
|
||||
"${mod}+l" = "exec ${getExe pkgs.gtklock} -d";
|
||||
"${mod}+Return" = "exec ${lib.getExe pkgs.kitty} ${lib.getExe pkgs.tmux}";
|
||||
"${mod}+Shift+e" = "input * xkb_layout latam";
|
||||
"${mod}+Shift+u" = "input * xkb_layout us";
|
||||
"${mod}+p" = "exec ${grimshot} copy active";
|
||||
"${mod}+Shift+p" = "exec ${grimshot} copy area";
|
||||
"${mod}+Ctrl+p" = "exec ${grimshot} copy window";
|
||||
"${mod}+Shift+s" = "exec ${grimshot} copy area";
|
||||
"${mod}+Tab" = "focus right";
|
||||
"${mod}+Shift+Tab" = "focus left";
|
||||
"${mod}+Shift+w" = "move workspace to output right";
|
||||
};
|
||||
|
||||
window.commands = [
|
||||
# (No) Title Bars
|
||||
startup = [
|
||||
{
|
||||
command = "border pixel 5";
|
||||
criteria.class = "^.*";
|
||||
command = "${lib.getExe pkgs.sway} 'workspace 1; exec ${lib.getExe pkgs.firefox}'";
|
||||
}
|
||||
|
||||
{
|
||||
command = "floating enabled";
|
||||
criteria.class = "floating";
|
||||
command = "${lib.getExe pkgs.sway} 'workspace 2; exec ${lib.getExe pkgs.tdesktop}'";
|
||||
}
|
||||
{
|
||||
command = "${lib.getExe pkgs.sway} 'workspace 2; exec ${lib.getExe pkgs.gajim}'";
|
||||
}
|
||||
{
|
||||
command = "${lib.getExe pkgs.swaybg} -m fill -i ${config.home.homeDirectory}/Pictures/wallpapers/jupiter.png";
|
||||
always = true;
|
||||
}
|
||||
{
|
||||
command = "${lib.getExe pkgs.networkmanagerapplet}";
|
||||
}
|
||||
];
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue