aboutsummaryrefslogtreecommitdiff
path: root/roles/home/desktop
diff options
context:
space:
mode:
authorCaroline Larimore <caroline@larimo.re>2025-02-07 05:02:20 -0800
committerCaroline Larimore <caroline@larimo.re>2025-04-14 18:58:47 -0700
commit4e0d8adb6fb1bb143a15b2b0ed80a82c58fbb317 (patch)
tree370bc9f7a7c9f0f3b2f2ec12ad6ccc9804e476c7 /roles/home/desktop
parentcf4129bb33d19e2e9a795058aa5db75a0aa9ce36 (diff)
migration: i3
Diffstat (limited to 'roles/home/desktop')
-rw-r--r--roles/home/desktop/default.nix2
-rw-r--r--roles/home/desktop/i3.nix239
2 files changed, 0 insertions, 241 deletions
diff --git a/roles/home/desktop/default.nix b/roles/home/desktop/default.nix
index 38b361c..5224afe 100644
--- a/roles/home/desktop/default.nix
+++ b/roles/home/desktop/default.nix
@@ -57,8 +57,6 @@ let cfg = config.home.roles.desktop; in {
};
config = mkIf cfg.enable {
- xsession.windowManager.i3.enable = true;
-
gtk.enable = true;
programs = {
diff --git a/roles/home/desktop/i3.nix b/roles/home/desktop/i3.nix
deleted file mode 100644
index 2653c4d..0000000
--- a/roles/home/desktop/i3.nix
+++ /dev/null
@@ -1,239 +0,0 @@
-{ config, pkgs, ... }:
-
-{
- xsession.windowManager.i3 = {
- config = let
- #NOTE: Alt (Mod1) and meta (Mod4) have been swapped by keyd.
- mod = "Mod4";
-
- ws0 = "0:Main";
- ws1 = "1:Terminal";
- ws2 = "2:Browser";
- ws3 = "3:Chat";
- ws4 = "4:Gaming";
- ws5 = "5";
- ws6 = "6";
- ws7 = "7";
- ws8 = "8:Meow";
- ws9 = "9:Music";
- ws10 = "10:Misc";
- ws11 = "11:Empty";
-
- output = {
- primary = "primary";
- left = "DVI-D-0";
- right = "DisplayPort-1 HDMI-A-0";
- };
- in {
- modifier = "${mod}";
-
- fonts = {
- names = [ "monospace" ];
- size = 8.0;
- };
-
- colors = let c = config.theme.colors; in {
- focused = {
- border = "#${c.fg2}";
- background = "#${c.fg2}";
- text = "#${c.bg}";
- indicator = "#${c.fg2}";
- childBorder = "#${c.fg2}";
- };
-
- focusedInactive = {
- border = "#${c.bg1}";
- background = "#${c.bg1}";
- text = "#${c.fg}";
- indicator = "#${c.bg1}";
- childBorder = "#${c.bg1}";
- };
-
- unfocused = {
- border = "#${c.bg}";
- background = "#${c.bg}";
- text = "#${c.fg}";
- indicator = "#${c.bg}";
- childBorder = "#${c.bg}";
- };
- };
-
- gaps.inner = 8;
-
- workspaceOutputAssign = [
- { workspace = "${ws0}"; output = output.primary; }
- { workspace = "${ws1}"; output = output.primary; }
-
- { workspace = "${ws2}"; output = output.left; }
- { workspace = "${ws3}"; output = output.left; }
-
- { workspace = "${ws4}"; output = output.primary; }
-
- { workspace = "${ws5}"; output = output.primary; }
- { workspace = "${ws6}"; output = output.primary; }
- { workspace = "${ws7}"; output = output.primary; }
-
- { workspace = "${ws8}"; output = output.primary; }
- { workspace = "${ws9}"; output = output.right; }
- { workspace = "${ws10}"; output = output.primary; }
-
- { workspace = "${ws11}"; output = output.primary; }
- ];
-
- assigns = {
- "${ws2}" = [ { class = "firefox"; } ];
- "${ws3}" = [ { class = "discord"; } ];
- "${ws4}" = [
- { class = "steam"; }
- { class = "prismlauncher"; }
- ];
-
- "${ws8}" = [ { class = "qbittorrent"; } ];
- "${ws9}" = [ { title = "cmus"; } ];
- };
-
- startup = [
- { command = "polybar-msg cmd quit"; always = true; notification = false; }
- { command = "polybar"; always = true; notification = false; }
- { command = "systemctl --user restart picom"; always = true; notification = false; }
- { command = "${pkgs.feh}/bin/feh --bg-fill ${../../../assets/bg/${config.theme.background}}"; always = true; notification = false; }
- { command = "${pkgs.fcitx5}/bin/fcitx5 -r -d"; always = true; notification = false; }
-
- { command = "${pkgs.premid}/bin/premid --no-sandbox"; always = false; notification = false; }
- ];
-
- keybindings = {
- "${mod}+Shift+c" = "reload";
- "${mod}+Shift+r" = "restart";
- "${mod}+Shift+e" = "exec \"i3-nagbar -t warning -m 'You pressed the exit shortcut. Do you really want to exit i3? This will end your X session.' -B 'Yes, exit i3' 'i3-msg exit'\"";
-
- "${mod}+q" = "kill";
- "${mod}+d" = "exec \"rofi -modi drun,run -show drun\"";
- "${mod}+Return" = "exec kitty";
-
- "${mod}+Num_Lock" = "exec --no-startup-id polybar-msg cmd toggle";
-
- # Screenshots
- #TODO: screen and full should be swapped, but currently screen is fucky :'(
- "Shift+Print" = "exec --no-startup-id ${pkgs.flameshot}/bin/flameshot screen -c";
- "Print" = "exec --no-startup-id ${pkgs.flameshot}/bin/flameshot full -c";
- "${mod}+Shift+s" = "exec --no-startup-id ${pkgs.flameshot}/bin/flameshot gui -c";
- "Mod1+Shift+s" = "exec --no-startup-id ${pkgs.flameshot}/bin/flameshot gui -c";
- "${mod}+Ctrl+Shift+s" = "exec --no-startup-id ${pkgs.flameshot}/bin/flameshot launcher -c";
-
- # Media keys
- "XF86AudioRaiseVolume" = "exec --no-startup-id ${pkgs.pulseaudio}/bin/pactl set-sink-volume @DEFAULT_SINK@ +2%";
- "XF86AudioLowerVolume" = "exec --no-startup-id ${pkgs.pulseaudio}/bin/pactl set-sink-volume @DEFAULT_SINK@ -2%";
- "XF86AudioMute" = "exec --no-startup-id ${pkgs.pulseaudio}/bin/pactl set-sink-mute @DEFAULT_SINK@ toggle";
- "XF86AudioMicMute" = "exec --no-startup-id ${pkgs.pulseaudio}/bin/pactl set-source-mute @DEFAULT_SOURCE@ toggle";
-
- "XF86AudioPlay" = "exec --no-startup-id \"playerctl --player=cmus,firefox,%any play-pause\"";
- "XF86AudioPause" = "exec --no-startup-id \"playerctl --player=cmus,firefox,%any play-pause\"";
- "XF86AudioStop" = "exec --no-startup-id \"playerctl --player=cmus,firefox,%any stop\"";
- "XF86AudioNext" = "exec --no-startup-id \"playerctl --player=cmus,firefox,%any next\"";
- "XF86AudioPrev" = "exec --no-startup-id \"playerctl --player=cmus,firefox,%any previous\"";
-
- # Media controller widget
- "${mod}+m" = "exec --no-startup-id eww-toggle music --arg pos=center --arg gaps=false";
- "${mod}+Ctrl+m" = "exec --no-startup-id eww-toggle music --arg pos=right --arg gaps=true";
- "${mod}+Shift+m" = "exec --no-startup-id eww-toggle music --arg pos=center --arg gaps=true";
- "${mod}+Shift+Ctrl+m" = "exec --no-startup-id eww-toggle music --arg pos=right --arg gaps=false";
-
- # Workspaces
- "${mod}+grave" = "workspace number ${ws0}";
- "${mod}+1" = "workspace number ${ws1}";
- "${mod}+2" = "workspace number ${ws2}";
- "${mod}+3" = "workspace number ${ws3}";
- "${mod}+4" = "workspace number ${ws4}";
- "${mod}+5" = "workspace number ${ws5}";
- "${mod}+6" = "workspace number ${ws6}";
- "${mod}+7" = "workspace number ${ws7}";
- "${mod}+8" = "workspace number ${ws8}";
- "${mod}+9" = "workspace number ${ws9}";
- "${mod}+0" = "workspace number ${ws10}";
- "${mod}+equal" = "workspace number ${ws11}";
-
- # Move active workspace
- "${mod}+comma" = "move workspace to output ${output.left}";
- "${mod}+period" = "move workspace to output ${output.primary}";
- "${mod}+slash" = "move workspace to output ${output.right}";
-
- # Layout
- "${mod}+z" = "layout stacking";
- "${mod}+x" = "layout tabbed";
- "${mod}+c" = "layout toggle split";
-
- # Focus
- "${mod}+h" = "focus left";
- "${mod}+j" = "focus down";
- "${mod}+k" = "focus up";
- "${mod}+l" = "focus right";
-
- "${mod}+Left" = "focus left";
- "${mod}+Down" = "focus down";
- "${mod}+Up" = "focus up";
- "${mod}+Right" = "focus right";
-
- "${mod}+space" = "focus mode_toggle";
- "${mod}+a" = "focus parent";
-
- # Move focused container
- "${mod}+Shift+h" = "move left";
- "${mod}+Shift+j" = "move down";
- "${mod}+Shift+k" = "move up";
- "${mod}+Shift+l" = "move right";
-
- "${mod}+Shift+Left" = "move left";
- "${mod}+Shift+Down" = "move down";
- "${mod}+Shift+Up" = "move up";
- "${mod}+Shift+Right" = "move right";
-
- # Misc container binds
- "${mod}+Shift+space" = "floating toggle";
- "${mod}+f" = "fullscreen toggle";
-
- "${mod}+w" = "split h";
- "${mod}+e" = "split v";
-
- "${mod}+r" = "mode resize";
-
- # Move focused container to workspace
- "${mod}+Shift+grave" = "move container to workspace number ${ws0}";
- "${mod}+Shift+1" = "move container to workspace number ${ws1}";
- "${mod}+Shift+2" = "move container to workspace number ${ws2}";
- "${mod}+Shift+3" = "move container to workspace number ${ws3}";
- "${mod}+Shift+4" = "move container to workspace number ${ws4}";
- "${mod}+Shift+5" = "move container to workspace number ${ws5}";
- "${mod}+Shift+6" = "move container to workspace number ${ws6}";
- "${mod}+Shift+7" = "move container to workspace number ${ws7}";
- "${mod}+Shift+8" = "move container to workspace number ${ws8}";
- "${mod}+Shift+9" = "move container to workspace number ${ws9}";
- "${mod}+Shift+0" = "move container to workspace number ${ws10}";
- };
-
- modes = {
- resize = {
- "h" = "resize shrink width 10 px or 10 ppt";
- "j" = "resize grow height 10 px or 10 ppt";
- "k" = "resize shrink height 10 px or 10 ppt";
- "l" = "resize grow width 10 px or 10 ppt";
-
- "Left" = "resize shrink width 10 px or 10 ppt";
- "Down" = "resize grow height 10 px or 10 ppt";
- "Up" = "resize shrink height 10 px or 10 ppt";
- "Right" = "resize grow width 10 px or 10 ppt";
-
- "Return" = "mode default";
- "Escape" = "mode default";
- "${mod}+r" = "mode default";
- };
- };
-
- bars = [];
- };
-
- extraConfig = ''
- default_border normal 0
- '';
- };
-}