fix: collection of small fixes
This commit is contained in:
@@ -3,6 +3,7 @@ local M = {}
|
|||||||
-- Open a command in a simple centered floating window
|
-- Open a command in a simple centered floating window
|
||||||
function M.open_terminal_app(cmd)
|
function M.open_terminal_app(cmd)
|
||||||
local buf = vim.api.nvim_create_buf(false, true)
|
local buf = vim.api.nvim_create_buf(false, true)
|
||||||
|
vim.bo[buf].bufhidden = "wipe"
|
||||||
|
|
||||||
local lines = vim.o.lines - vim.o.cmdheight - (vim.o.laststatus > 0 and 1 or 0)
|
local lines = vim.o.lines - vim.o.cmdheight - (vim.o.laststatus > 0 and 1 or 0)
|
||||||
local w = math.floor(vim.o.columns * 0.95)
|
local w = math.floor(vim.o.columns * 0.95)
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ vim.o.signcolumn = 'yes' -- Always show signcolumn (less flicker)
|
|||||||
vim.o.splitbelow = true -- Horizontal splits will be below
|
vim.o.splitbelow = true -- Horizontal splits will be below
|
||||||
vim.o.splitkeep = 'screen' -- Reduce scroll during window split
|
vim.o.splitkeep = 'screen' -- Reduce scroll during window split
|
||||||
vim.o.splitright = true -- Vertical splits will be to the right
|
vim.o.splitright = true -- Vertical splits will be to the right
|
||||||
vim.o.wrap = false -- Don't visually wrap lines (toggle with \w)
|
vim.o.wrap = false -- Don't visually wrap lines
|
||||||
vim.o.winborder = 'rounded' -- Use border in floating windows
|
vim.o.winborder = 'rounded' -- Use border in floating windows
|
||||||
vim.o.pumborder = 'rounded' -- Use border in popup menu
|
vim.o.pumborder = 'rounded' -- Use border in popup menu
|
||||||
vim.o.cmdheight = 0 -- Hide the command line when not in use
|
vim.o.cmdheight = 0 -- Hide the command line when not in use
|
||||||
|
|||||||
@@ -49,6 +49,7 @@ leader("ef", function()
|
|||||||
local file = vim.api.nvim_buf_get_name(0)
|
local file = vim.api.nvim_buf_get_name(0)
|
||||||
MiniFiles.open(vim.uv.fs_stat(file) and file or nil)
|
MiniFiles.open(vim.uv.fs_stat(file) and file or nil)
|
||||||
end, "File directory")
|
end, "File directory")
|
||||||
|
leader("ey", function() vim.fn.setreg("+", vim.api.nvim_buf_get_name(0)) end, "Yank absolute path")
|
||||||
|
|
||||||
-- Find
|
-- Find
|
||||||
leader("fb", function() MiniPick.builtin.buffers() end, "Buffers")
|
leader("fb", function() MiniPick.builtin.buffers() end, "Buffers")
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ Config.now_if_args(function()
|
|||||||
local filetypes = {
|
local filetypes = {
|
||||||
'html', 'css', 'lua', 'go', 'php', 'blade', 'sql', 'javascript',
|
'html', 'css', 'lua', 'go', 'php', 'blade', 'sql', 'javascript',
|
||||||
'typescript', 'typescriptreact', 'svelte', 'dockerfile', 'yaml', 'markdown', 'dart',
|
'typescript', 'typescriptreact', 'svelte', 'dockerfile', 'yaml', 'markdown', 'dart',
|
||||||
'json', 'xml', 'toml', 'sh', 'bash', 'zsh', 'gitcommit', 'diff', 'regex', 'http'
|
'json', 'xml', 'toml', 'sh', 'bash', 'zsh', 'just', 'gitcommit', 'diff', 'regex', 'http'
|
||||||
}
|
}
|
||||||
|
|
||||||
Config.autocmd('FileType', filetypes, function(ev)
|
Config.autocmd('FileType', filetypes, function(ev)
|
||||||
|
|||||||
Reference in New Issue
Block a user