From e49a46d90b3f482a7fb5a9682b65b6398f605529 Mon Sep 17 00:00:00 2001 From: genofire Date: Thu, 7 Oct 2021 22:32:45 +0200 Subject: [PATCH] nix sway - WIP --- sway.nix | 87 ++++++++++++++++++++++++++++++++++++++++++++------------ 1 file changed, 69 insertions(+), 18 deletions(-) diff --git a/sway.nix b/sway.nix index ffbf89b..ea4135a 100644 --- a/sway.nix +++ b/sway.nix @@ -1,4 +1,4 @@ -{ pkgs, ... }: +{ config, pkgs, ... }: { home.sessionVariables = { @@ -25,27 +25,78 @@ slurp ]; - #wayland.windowManager.sway = { - # enable = true; - # xwayland = false; - # config = { - # keybinding = [ - # ]; - # }; - #}; + wayland.windowManager.sway = + let + ws1="1💬"; + #ws2="2📝"; + ws2="2🌟"; + ws3="3🍁"; + ws4="4🍀"; + ws5="5🌈"; + ws6="6💎"; + ws7="7🎥"; + ws8="8🌍"; + ws9="9🔒"; + ws10="10🌀"; + + modifier = config.wayland.windowManager.sway.config.modifier; + in { + enable = false; + xwayland = false; + config = { + terminal = "alacritty"; + menu = "bemenu-run -i -p 'Run:' --fn 'pango:monospace 7'"; + bars = [{ + position = "top"; + }]; + #keybinding = [ + #]; + assigns = { + "${ws1}" = [ + { app_id = "(?i)empathy"; } + { app_id = "(?i)gajim"; } + { app_id = "(?i)dino"; } + { app_id = "(?i)pidgin"; } + ]; + "${ws2}" = [ + { app_id = "(?i)thunderbird"; } + { app_id = "(?i)evolution"; } + ]; + "${ws4}" = [ + { app_id = "(?i)atril"; } + { app_id = "(?i)evince"; } + ]; + "${ws7}" = [ + { app_id = "(?i)mpv"; } + ]; + "${ws8}" = [ + { app_id = "(?i)firefox"; } + { app_id = "(?i)firefoxdeveloperedition"; } + ]; + }; + window.commands = [ + { command = "move to scratchpad"; criteria = { title = "Firefox.* Sharing Indicator"; }; } + { command = "sticky enable"; criteria = { title = "Picture-in-Picture"; }; } + { command = "floating enable"; criteria = { title = "Picture-in-Picture"; }; } + { command = "floating enable"; criteria = { title = "Extension: \(Tree Style Tab\) - .*"; }; } + ]; + }; + }; + services.gammastep = { enable = true; provider = "geoclue2"; # duskTime = "22:00-23:00"; # dawnTime = "6:00-10:00"; }; - #programs.alacritty = { - # enable = true; - # settings = { - # background_opacity = 0.95; - # font.size = 8; - # schemes.base16.primary.background = "0x0a0a0a"; - # colors = "*base16"; - # }; - #}; + + programs.alacritty = { + enable = false; + settings = { + background_opacity = 0.95; + font.size = 8; + schemes.base16.primary.background = "0x0a0a0a"; + colors = "*base16"; + }; + }; }