Use true-zen.nvim for maximizing buffers
This commit is contained in:
parent
734aebfa00
commit
23bbab50e9
@ -368,6 +368,12 @@ return require('packer').startup(function(use)
|
|||||||
require('plugins.session-lens')
|
require('plugins.session-lens')
|
||||||
end
|
end
|
||||||
}
|
}
|
||||||
|
use {
|
||||||
|
'Pocco81/true-zen.nvim',
|
||||||
|
config = function()
|
||||||
|
require('plugins.true-zen-nvim')
|
||||||
|
end
|
||||||
|
}
|
||||||
use {
|
use {
|
||||||
'folke/which-key.nvim',
|
'folke/which-key.nvim',
|
||||||
config = function()
|
config = function()
|
||||||
|
@ -8,8 +8,9 @@ require("toggleterm").setup({
|
|||||||
vim.keymap.set('n', [[<M-=>]], [[<Cmd>ToggleTerm direction=float<CR>]])
|
vim.keymap.set('n', [[<M-=>]], [[<Cmd>ToggleTerm direction=float<CR>]])
|
||||||
vim.keymap.set('n', [[<M-\>]], [[<Cmd>ToggleTerm direction=horizontal<CR>]])
|
vim.keymap.set('n', [[<M-\>]], [[<Cmd>ToggleTerm direction=horizontal<CR>]])
|
||||||
-- tmux muscle-memory for fullscreening nvim window
|
-- tmux muscle-memory for fullscreening nvim window
|
||||||
vim.keymap.set('n', [[<C-a>z]], [[<Cmd>ToggleTermToggleAll<CR>]])
|
-- replaced with true-zen.nvim
|
||||||
vim.keymap.set('t', [[<C-a>z]], [[<Cmd>tab split<CR>]])
|
-- vim.keymap.set('n', [[<C-a>z]], [[<Cmd>ToggleTermToggleAll<CR>]])
|
||||||
|
-- vim.keymap.set('t', [[<C-a>z]], [[<Cmd>tab split<CR>]])
|
||||||
vim.keymap.set('t', '<Esc>', [[<C-\><C-n>]])
|
vim.keymap.set('t', '<Esc>', [[<C-\><C-n>]])
|
||||||
vim.keymap.set('t', '<C-j>', [[<Cmd>wincmd h<CR>]])
|
vim.keymap.set('t', '<C-j>', [[<Cmd>wincmd h<CR>]])
|
||||||
vim.keymap.set('t', '<C-k>', [[<Cmd>wincmd k<CR>]])
|
vim.keymap.set('t', '<C-k>', [[<Cmd>wincmd k<CR>]])
|
||||||
@ -38,3 +39,22 @@ function _gitui_toggle()
|
|||||||
end
|
end
|
||||||
|
|
||||||
vim.keymap.set('n', '<leader>G', '<cmd>lua _gitui_toggle()<CR>', { noremap = true, silent = true })
|
vim.keymap.set('n', '<leader>G', '<cmd>lua _gitui_toggle()<CR>', { noremap = true, silent = true })
|
||||||
|
|
||||||
|
-- Custom clx commandline hacker news terminal
|
||||||
|
local clx = Terminal:new({
|
||||||
|
cmd = 'clx',
|
||||||
|
direction = 'float',
|
||||||
|
float_opts = {
|
||||||
|
border = "curved",
|
||||||
|
width = function() return math.ceil(vim.o.columns * 0.8) end,
|
||||||
|
height = function() return math.ceil(vim.o.lines * 0.8) end,
|
||||||
|
winblend = 3,
|
||||||
|
},
|
||||||
|
hidden = true,
|
||||||
|
})
|
||||||
|
|
||||||
|
function _clx_toggle()
|
||||||
|
clx:toggle()
|
||||||
|
end
|
||||||
|
|
||||||
|
vim.keymap.set('n', '<leader>H', '<cmd>lua _clx_toggle()<CR>', { noremap = true, silent = true })
|
||||||
|
10
lua/plugins/true-zen-nvim.lua
Normal file
10
lua/plugins/true-zen-nvim.lua
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
require('true-zen').setup()
|
||||||
|
|
||||||
|
vim.keymap.set('n', '<leader>zn', [[<Cmd>:TZNarrow<CR>]], { noremap = true, silent = true })
|
||||||
|
vim.keymap.set('v', '<leader>zn', [[<Cmd>:'<,'>TZNarrow<CR>]], { noremap = true, silent = true })
|
||||||
|
vim.keymap.set('n', '<leader>zf', [[<Cmd>:TZFocus<CR>]], { noremap = true, silent = true })
|
||||||
|
vim.keymap.set('n', '<leader>zm', [[<Cmd>:TZMinimalist<CR>]], { noremap = true, silent = true })
|
||||||
|
vim.keymap.set('n', '<leader>za', [[<Cmd>:TZAtaraxis<CR>]], { noremap = true, silent = true })
|
||||||
|
-- tmux muscle-memory for fullscreening nvim window
|
||||||
|
vim.keymap.set('n', [[<C-a>z]], [[<Cmd>:TZFocus<CR>]])
|
||||||
|
vim.keymap.set('t', [[<C-a>z]], [[<Cmd>:TZFocus<CR>]])
|
Loading…
Reference in New Issue
Block a user