update multiple configurations
This commit is contained in:
parent
d3fb4fa158
commit
182016e83a
11 changed files with 87 additions and 21 deletions
|
|
@ -47,3 +47,4 @@ theme = nightfox
|
||||||
# palette = 15=#b5bfe2
|
# palette = 15=#b5bfe2
|
||||||
|
|
||||||
keybind = all:ctrl+shift+period=text:\x1b\x1f\x4c\x23\x1f
|
keybind = all:ctrl+shift+period=text:\x1b\x1f\x4c\x23\x1f
|
||||||
|
keybind = shift+enter=text:\n
|
||||||
|
|
|
||||||
|
|
@ -133,5 +133,61 @@ keymap.super {
|
||||||
}
|
}
|
||||||
|
|
||||||
-- split type - use insert direction to control next window placement
|
-- split type - use insert direction to control next window placement
|
||||||
yabai_key { key = 'v', commands = { 'window --insert east' } }
|
-- yabai_key { key = 'v', commands = { 'window --insert east' } }
|
||||||
yabai_key { key = 'v', mods = { 'shift' }, commands = { 'window --insert south' } }
|
-- yabai_key { mods = { 'shift' }, key = 'v', commands = { 'window --insert south' } }
|
||||||
|
|
||||||
|
yabai_key { key = 'v', commands = { 'config split_type vertical' } }
|
||||||
|
yabai_key { mods = { 'shift' }, key = 'v', commands = { 'config split_type horizontal' } }
|
||||||
|
|
||||||
|
-- Resize mode
|
||||||
|
local resize_mode = hs.hotkey.modal.new()
|
||||||
|
|
||||||
|
-- Function to show resize mode indicator
|
||||||
|
function resize_mode:entered() hs.alert.show('Resize Mode', { textSize = 20, radius = 10 }, 999999) end
|
||||||
|
|
||||||
|
function resize_mode:exited() hs.alert.closeAll() end
|
||||||
|
|
||||||
|
-- Enter resize mode
|
||||||
|
|
||||||
|
keymap.super {
|
||||||
|
key = 'r',
|
||||||
|
message = 'Enter resize mode',
|
||||||
|
fn = function() resize_mode:enter() end,
|
||||||
|
}
|
||||||
|
|
||||||
|
-- Exit resize mode (escape or return)
|
||||||
|
resize_mode:bind({}, 'escape', function() resize_mode:exit() end)
|
||||||
|
|
||||||
|
resize_mode:bind({}, 'return', function() resize_mode:exit() end)
|
||||||
|
|
||||||
|
-- Resize bindings (no modifiers needed in resize mode)
|
||||||
|
resize_mode:bind({}, 'h', function() os.execute(yabai_cmd .. ' -m window --resize left:-20:0 || ' .. yabai_cmd .. ' -m window --resize right:-20:0') end)
|
||||||
|
|
||||||
|
resize_mode:bind({}, 'j', function() os.execute(yabai_cmd .. ' -m window --resize bottom:0:20 || ' .. yabai_cmd .. ' -m window --resize top:0:20') end)
|
||||||
|
|
||||||
|
resize_mode:bind({}, 'k', function() os.execute(yabai_cmd .. ' -m window --resize top:0:-20 || ' .. yabai_cmd .. ' -m window --resize bottom:0:-20') end)
|
||||||
|
|
||||||
|
resize_mode:bind({}, 'l', function() os.execute(yabai_cmd .. ' -m window --resize right:20:0 || ' .. yabai_cmd .. ' -m window --resize left:20:0') end)
|
||||||
|
|
||||||
|
-- Shift variants for larger increments
|
||||||
|
resize_mode:bind(
|
||||||
|
{ 'shift' },
|
||||||
|
'h',
|
||||||
|
function() os.execute(yabai_cmd .. ' -m window --resize left:-50:0 || ' .. yabai_cmd .. ' -m window --resize right:-50:0') end
|
||||||
|
)
|
||||||
|
|
||||||
|
resize_mode:bind({ 'shift' }, 'j', function() os.execute(yabai_cmd .. ' -m window --resize bottom:0:50 || ' .. yabai_cmd .. ' -m window --resize top:0:50') end)
|
||||||
|
|
||||||
|
resize_mode:bind(
|
||||||
|
{ 'shift' },
|
||||||
|
'k',
|
||||||
|
function() os.execute(yabai_cmd .. ' -m window --resize top:0:-50 || ' .. yabai_cmd .. ' -m window --resize bottom:0:-50') end
|
||||||
|
)
|
||||||
|
|
||||||
|
resize_mode:bind({ 'shift' }, 'l', function() os.execute(yabai_cmd .. ' -m window --resize right:50:0 || ' .. yabai_cmd .. ' -m window --resize left:50:0') end)
|
||||||
|
|
||||||
|
-- Equalize windows
|
||||||
|
resize_mode:bind({}, 'e', function()
|
||||||
|
os.execute(yabai_cmd .. ' -m space --balance')
|
||||||
|
resize_mode:exit()
|
||||||
|
end)
|
||||||
|
|
|
||||||
|
|
@ -574,8 +574,20 @@ map('n', '<leader>ws', '<cmd>split<cr>', 'Split window horizontally')
|
||||||
map('n', '<leader>wv', '<cmd>vsplit<cr>', 'Split window vertically')
|
map('n', '<leader>wv', '<cmd>vsplit<cr>', 'Split window vertically')
|
||||||
map('n', '<leader>wq', '<C-w>q', 'Close window')
|
map('n', '<leader>wq', '<C-w>q', 'Close window')
|
||||||
|
|
||||||
-- Terminal mode keymap to unfocus and return to previous window
|
-- Visual mode
|
||||||
vim.keymap.set('t', '<C-q>', '<C-\\><C-n><C-w>p', { desc = 'Unfocus terminal and return to editor' })
|
map('v', '<C-h>', function() require('tmux').move_left() end, 'Move to left tmux pane')
|
||||||
|
map('v', '<C-l>', function() require('tmux').move_right() end, 'Move to right tmux pane')
|
||||||
|
map('v', '<C-j>', function() require('tmux').move_bottom() end, 'Move to bottom tmux pane')
|
||||||
|
map('v', '<C-k>', function() require('tmux').move_top() end, 'Move to top tmux pane')
|
||||||
|
|
||||||
|
-- Terminal mode
|
||||||
|
map('t', '<C-h>', function() require('tmux').move_left() end, 'Move to left tmux pane')
|
||||||
|
map('t', '<C-l>', function() require('tmux').move_right() end, 'Move to right tmux pane')
|
||||||
|
map('t', '<C-j>', function() require('tmux').move_bottom() end, 'Move to bottom tmux pane')
|
||||||
|
map('t', '<C-k>', function() require('tmux').move_top() end, 'Move to top tmux pane')
|
||||||
|
map('t', '<C-q>', '<C-\\><C-n>', 'Unfocus terminal and return to editor')
|
||||||
|
|
||||||
|
-- Auto commands
|
||||||
|
|
||||||
vim.api.nvim_create_autocmd('QuickFixCmdPost', {
|
vim.api.nvim_create_autocmd('QuickFixCmdPost', {
|
||||||
callback = function()
|
callback = function()
|
||||||
|
|
|
||||||
|
|
@ -30,9 +30,9 @@ for i = 1, 10, 1 do
|
||||||
padding_left = 1,
|
padding_left = 1,
|
||||||
background = {
|
background = {
|
||||||
color = colors.bg1,
|
color = colors.bg1,
|
||||||
border_width = 1,
|
-- border_width = 1,
|
||||||
height = 26,
|
height = 26,
|
||||||
border_color = colors.black,
|
-- border_color = colors.black,
|
||||||
},
|
},
|
||||||
popup = { background = { border_width = 5, border_color = colors.black } },
|
popup = { background = { border_width = 5, border_color = colors.black } },
|
||||||
})
|
})
|
||||||
|
|
@ -43,7 +43,7 @@ for i = 1, 10, 1 do
|
||||||
local space_bracket = sbar.add('bracket', { space.name }, {
|
local space_bracket = sbar.add('bracket', { space.name }, {
|
||||||
background = {
|
background = {
|
||||||
color = colors.transparent,
|
color = colors.transparent,
|
||||||
border_color = colors.bg2,
|
-- border_color = colors.bg2,
|
||||||
height = 28,
|
height = 28,
|
||||||
border_width = 2,
|
border_width = 2,
|
||||||
},
|
},
|
||||||
|
|
@ -77,11 +77,11 @@ for i = 1, 10, 1 do
|
||||||
space:set {
|
space:set {
|
||||||
icon = { highlight = selected },
|
icon = { highlight = selected },
|
||||||
label = { highlight = selected },
|
label = { highlight = selected },
|
||||||
background = { border_color = selected and colors.black or colors.bg2 },
|
background = { border_color = selected and colors.black },
|
||||||
drawing = selected or has_windows,
|
drawing = selected or has_windows,
|
||||||
}
|
}
|
||||||
space_bracket:set {
|
space_bracket:set {
|
||||||
background = { border_color = selected and colors.grey or colors.bg2 },
|
background = { border_color = selected and colors.grey },
|
||||||
}
|
}
|
||||||
end)
|
end)
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -20,8 +20,8 @@ set -g history-limit 2000
|
||||||
set-option -g detach-on-destroy off
|
set-option -g detach-on-destroy off
|
||||||
set-option -g status-position bottom # top
|
set-option -g status-position bottom # top
|
||||||
|
|
||||||
set-option -g default-terminal 'tmux-256color'
|
set-option -g default-terminal 'xterm-256color'
|
||||||
set-option -sa terminal-features ',xterm-kitty:RGB'
|
set-option -sa terminal-features ',xterm-kitty:RGB:extkeys'
|
||||||
# set -g default-terminal "screen-256color"
|
# set -g default-terminal "screen-256color"
|
||||||
# set -ga terminal-overrides ",xterm-256color*:Tc"
|
# set -ga terminal-overrides ",xterm-256color*:Tc"
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -11,7 +11,7 @@ yabai -m config window_gap 15
|
||||||
yabai -m config auto_balance off
|
yabai -m config auto_balance off
|
||||||
|
|
||||||
yabai -m config mouse_follows_focus off
|
yabai -m config mouse_follows_focus off
|
||||||
yabai -m config focus_follows_mouse autofocus
|
yabai -m config focus_follows_mouse off
|
||||||
yabai -m config mouse_modifier fn
|
yabai -m config mouse_modifier fn
|
||||||
yabai -m config mouse_action1 move
|
yabai -m config mouse_action1 move
|
||||||
yabai -m config mouse_action2 resize
|
yabai -m config mouse_action2 resize
|
||||||
|
|
|
||||||
|
|
@ -30,7 +30,6 @@
|
||||||
programs = {
|
programs = {
|
||||||
nh = {
|
nh = {
|
||||||
enable = true;
|
enable = true;
|
||||||
# package = pkgs.custom.nh;
|
|
||||||
clean.enable = true;
|
clean.enable = true;
|
||||||
clean.extraArgs = "--keep-since 4d --keep 3";
|
clean.extraArgs = "--keep-since 4d --keep 3";
|
||||||
flake = dots;
|
flake = dots;
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,7 @@
|
||||||
gui = {
|
gui = {
|
||||||
aerospace.enable = false;
|
aerospace.enable = false;
|
||||||
sketchybar.enable = true;
|
sketchybar.enable = true;
|
||||||
jankyborders.enable = false;
|
jankyborders.enable = true;
|
||||||
yabai.enable = true;
|
yabai.enable = true;
|
||||||
};
|
};
|
||||||
brew = {
|
brew = {
|
||||||
|
|
|
||||||
|
|
@ -1,15 +1,13 @@
|
||||||
{
|
{
|
||||||
inputs,
|
|
||||||
pkgs,
|
pkgs,
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
let
|
let
|
||||||
inherit (pkgs) lib callPackage;
|
inherit (pkgs) callPackage;
|
||||||
in
|
in
|
||||||
rec {
|
{
|
||||||
minimal-emacs-d = callPackage ./minimal-emacs-d { };
|
minimal-emacs-d = callPackage ./minimal-emacs-d { };
|
||||||
boomer = callPackage ./boomer { };
|
boomer = callPackage ./boomer { };
|
||||||
# nh = callPackage ./nh { };
|
|
||||||
whatsapp-for-mac = callPackage ./whatsapp-for-mac { };
|
whatsapp-for-mac = callPackage ./whatsapp-for-mac { };
|
||||||
sf-symbols = callPackage ./sf-symbols { full = true; };
|
sf-symbols = callPackage ./sf-symbols { full = true; };
|
||||||
sf-mono = callPackage ./sf-mono { };
|
sf-mono = callPackage ./sf-mono { };
|
||||||
|
|
|
||||||
|
|
@ -8,7 +8,7 @@
|
||||||
lua54Packages,
|
lua54Packages,
|
||||||
stdenv,
|
stdenv,
|
||||||
lib,
|
lib,
|
||||||
apple-sdk_12,
|
apple-sdk_14,
|
||||||
}:
|
}:
|
||||||
lua54Packages.buildLuaPackage rec {
|
lua54Packages.buildLuaPackage rec {
|
||||||
pname = "sbar";
|
pname = "sbar";
|
||||||
|
|
@ -30,5 +30,5 @@ lua54Packages.buildLuaPackage rec {
|
||||||
clang
|
clang
|
||||||
stdenv
|
stdenv
|
||||||
]
|
]
|
||||||
++ lib.optionals stdenv.isDarwin [ apple-sdk_12 ];
|
++ lib.optionals stdenv.isDarwin [ apple-sdk_14 ];
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@
|
||||||
xar,
|
xar,
|
||||||
cpio,
|
cpio,
|
||||||
}:
|
}:
|
||||||
stdenvNoCC.mkDerivation rec {
|
stdenvNoCC.mkDerivation {
|
||||||
pname = "sf-mono";
|
pname = "sf-mono";
|
||||||
version = "2025-04-05";
|
version = "2025-04-05";
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue