mirror of
https://github.com/nmasur/dotfiles
synced 2024-11-26 09:35:37 +00:00
clean up i3 sxhkd
This commit is contained in:
parent
5efa1eb269
commit
cb15963270
@ -147,6 +147,7 @@ in {
|
|||||||
"super + control + space" = ''${i3-msg} "focus mode_toggle"'';
|
"super + control + space" = ''${i3-msg} "focus mode_toggle"'';
|
||||||
"super + a" = ''${i3-msg} "focus parent"'';
|
"super + a" = ''${i3-msg} "focus parent"'';
|
||||||
|
|
||||||
|
# Launch terminal
|
||||||
"super + Return" = ''
|
"super + Return" = ''
|
||||||
${i3-msg} "exec --no-startup-id ${config.terminal}; workspace ${
|
${i3-msg} "exec --no-startup-id ${config.terminal}; workspace ${
|
||||||
workspaces."2"
|
workspaces."2"
|
||||||
@ -157,22 +158,31 @@ in {
|
|||||||
"super + shift + q" = ''
|
"super + shift + q" = ''
|
||||||
${pkgs.i3}/bin/i3-nagbar -t warning -m "Exit i3?" -B "Yes, exit i3" "${i3-msg} exit"'';
|
${pkgs.i3}/bin/i3-nagbar -t warning -m "Exit i3?" -B "Yes, exit i3" "${i3-msg} exit"'';
|
||||||
|
|
||||||
|
# Resize
|
||||||
"super + r : {h,j,k,l}" =
|
"super + r : {h,j,k,l}" =
|
||||||
''${i3-msg} "resize {shrink,grow} width 10px or 10 ppt"'';
|
''${i3-msg} "resize {shrink,grow} width 10px or 10 ppt"'';
|
||||||
"super + r : {j,k}" =
|
"super + r : {j,k}" =
|
||||||
''${i3-msg} "resize {shrink,grow} height 10px or 10 ppt"'';
|
''${i3-msg} "resize {shrink,grow} height 10px or 10 ppt"'';
|
||||||
|
|
||||||
} // (let
|
} // (
|
||||||
# Bind navigation
|
|
||||||
bindWorkspace = num: workspace:
|
# Bind navigation by number
|
||||||
lib.attrsets.nameValuePair ("super + ${num}")
|
let
|
||||||
(''${i3-msg} "workspace ${workspace}"'');
|
bindWorkspace = num: workspace:
|
||||||
in lib.mapAttrs' bindWorkspace workspaces) // (let
|
lib.attrsets.nameValuePair ("super + ${num}")
|
||||||
# Bind move container to workspace
|
(''${i3-msg} "workspace ${workspace}"'');
|
||||||
bindWorkspace = num: workspace:
|
in lib.mapAttrs' bindWorkspace workspaces
|
||||||
lib.attrsets.nameValuePair ("super + shift +${num}") (''
|
|
||||||
${i3-msg} "move container to workspace ${workspace}; workspace ${workspace}"'');
|
) // (
|
||||||
in lib.mapAttrs' bindWorkspace workspaces);
|
|
||||||
|
# Bind move container to workspace by number
|
||||||
|
let
|
||||||
|
bindWorkspace = num: workspace:
|
||||||
|
lib.attrsets.nameValuePair ("super + shift +${num}") (''
|
||||||
|
${i3-msg} "move container to workspace ${workspace}; workspace ${workspace}"'');
|
||||||
|
in lib.mapAttrs' bindWorkspace workspaces
|
||||||
|
|
||||||
|
);
|
||||||
|
|
||||||
programs.fish.functions = {
|
programs.fish.functions = {
|
||||||
update-lock-screen = lib.mkIf config.services.xserver.enable {
|
update-lock-screen = lib.mkIf config.services.xserver.enable {
|
||||||
|
Loading…
Reference in New Issue
Block a user