get rid of i3-wk-switch

This commit is contained in:
Ingolf Wagner 2023-05-28 11:32:42 +02:00
parent 9e0f37accd
commit aac47e072d
No known key found for this signature in database
GPG key ID: 76BF5F1928B9618B

View file

@ -11,17 +11,6 @@ let
background = theme.base03; background = theme.base03;
}; };
# switch to named workspaces
# todo : add version assert
i3-wk-switch = pkgs.i3-wk-switch.overrideAttrs (old: {
src = pkgs.fetchFromGitHub {
owner = "tmfink";
repo = "i3-wk-switch";
rev = "5f43bb8cbe7938eff476fc534b61c8fb6a700c8f";
sha256 = "sha256-DOBPI/wO+S8a6EzWJeVGODXeSixFl7SHTtHAq5DG8GU=";
};
});
backgroundCommand = pkgs.writers.writeDash "background" '' backgroundCommand = pkgs.writers.writeDash "background" ''
${pkgs.xorg.xrandr}/bin/xrandr | grep " connected" | \ ${pkgs.xorg.xrandr}/bin/xrandr | grep " connected" | \
${pkgs.gnused}/bin/sed -E "s/primary //" | \ ${pkgs.gnused}/bin/sed -E "s/primary //" | \
@ -269,16 +258,16 @@ in
"${cfg.config.modifier}+Shift+minus" = "move scratchpad"; "${cfg.config.modifier}+Shift+minus" = "move scratchpad";
"${cfg.config.modifier}+minus" = "scratchpad show"; "${cfg.config.modifier}+minus" = "scratchpad show";
"${cfg.config.modifier}+1" = "exec --no-startup-id ${i3-wk-switch}/bin/i3-wk-switch 1"; "${cfg.config.modifier}+1" = "workspace 1";
"${cfg.config.modifier}+2" = "exec --no-startup-id ${i3-wk-switch}/bin/i3-wk-switch 2"; "${cfg.config.modifier}+2" = "workspace 2";
"${cfg.config.modifier}+3" = "exec --no-startup-id ${i3-wk-switch}/bin/i3-wk-switch 3"; "${cfg.config.modifier}+3" = "workspace 3";
"${cfg.config.modifier}+4" = "exec --no-startup-id ${i3-wk-switch}/bin/i3-wk-switch 4"; "${cfg.config.modifier}+4" = "workspace 4";
"${cfg.config.modifier}+5" = "exec --no-startup-id ${i3-wk-switch}/bin/i3-wk-switch 5"; "${cfg.config.modifier}+5" = "workspace 5";
"${cfg.config.modifier}+6" = "exec --no-startup-id ${i3-wk-switch}/bin/i3-wk-switch 6"; "${cfg.config.modifier}+6" = "workspace 6";
"${cfg.config.modifier}+7" = "exec --no-startup-id ${i3-wk-switch}/bin/i3-wk-switch 7"; "${cfg.config.modifier}+7" = "workspace 7";
"${cfg.config.modifier}+8" = "exec --no-startup-id ${i3-wk-switch}/bin/i3-wk-switch 8"; "${cfg.config.modifier}+8" = "workspace 8";
"${cfg.config.modifier}+9" = "exec --no-startup-id ${i3-wk-switch}/bin/i3-wk-switch 9"; "${cfg.config.modifier}+9" = "workspace 9";
"${cfg.config.modifier}+0" = "exec --no-startup-id ${i3-wk-switch}/bin/i3-wk-switch 10"; "${cfg.config.modifier}+0" = "workspace 10";
"${cfg.config.modifier}+Shift+1" = "move container to workspace number 1"; "${cfg.config.modifier}+Shift+1" = "move container to workspace number 1";
"${cfg.config.modifier}+Shift+2" = "move container to workspace number 2"; "${cfg.config.modifier}+Shift+2" = "move container to workspace number 2";
@ -308,7 +297,7 @@ in
${pkgs.rofi}/bin/rofi -dmenu -p 'Select Workspace' | \ ${pkgs.rofi}/bin/rofi -dmenu -p 'Select Workspace' | \
while read line while read line
do do
${i3-wk-switch}/bin/i3-wk-switch "$line" ${pkgs.i3}/bin/i3-msg workspace "$line"
done done
''; '';
in in