mirror of
https://github.com/nmasur/dotfiles
synced 2024-12-27 07:34:52 +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 + a" = ''${i3-msg} "focus parent"'';
|
||||
|
||||
# Launch terminal
|
||||
"super + Return" = ''
|
||||
${i3-msg} "exec --no-startup-id ${config.terminal}; workspace ${
|
||||
workspaces."2"
|
||||
@ -157,22 +158,31 @@ in {
|
||||
"super + shift + q" = ''
|
||||
${pkgs.i3}/bin/i3-nagbar -t warning -m "Exit i3?" -B "Yes, exit i3" "${i3-msg} exit"'';
|
||||
|
||||
# Resize
|
||||
"super + r : {h,j,k,l}" =
|
||||
''${i3-msg} "resize {shrink,grow} width 10px or 10 ppt"'';
|
||||
"super + r : {j,k}" =
|
||||
''${i3-msg} "resize {shrink,grow} height 10px or 10 ppt"'';
|
||||
|
||||
} // (let
|
||||
# Bind navigation
|
||||
bindWorkspace = num: workspace:
|
||||
lib.attrsets.nameValuePair ("super + ${num}")
|
||||
(''${i3-msg} "workspace ${workspace}"'');
|
||||
in lib.mapAttrs' bindWorkspace workspaces) // (let
|
||||
# Bind move container to workspace
|
||||
bindWorkspace = num: workspace:
|
||||
lib.attrsets.nameValuePair ("super + shift +${num}") (''
|
||||
${i3-msg} "move container to workspace ${workspace}; workspace ${workspace}"'');
|
||||
in lib.mapAttrs' bindWorkspace workspaces);
|
||||
} // (
|
||||
|
||||
# Bind navigation by number
|
||||
let
|
||||
bindWorkspace = num: workspace:
|
||||
lib.attrsets.nameValuePair ("super + ${num}")
|
||||
(''${i3-msg} "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 = {
|
||||
update-lock-screen = lib.mkIf config.services.xserver.enable {
|
||||
|
Loading…
Reference in New Issue
Block a user