mirror of
https://github.com/cap153/nvim.git
synced 2026-04-23 05:45:23 +08:00
增删一些插件
This commit is contained in:
parent
e4487aa27f
commit
996cfc643b
9 changed files with 145 additions and 46 deletions
|
|
@ -4,11 +4,19 @@ return {
|
|||
dependencies = { "nvim-tree/nvim-web-devicons" },
|
||||
config = function()
|
||||
-- ctrl+t打开文件查找
|
||||
vim.keymap.set('n', '<c-t>', '<cmd>FzfLua files<cr>', {})
|
||||
vim.keymap.set('n', '<c-t>', function()
|
||||
-- 查找当前文件所在目录及其父目录下是否有 .git 文件夹
|
||||
local is_git = vim.fs.root(0, '.git')
|
||||
if is_git then
|
||||
require('fzf-lua').git_files()
|
||||
else
|
||||
require('fzf-lua').files()
|
||||
end
|
||||
end)
|
||||
-- ctrl+f打开字符串查找
|
||||
vim.keymap.set('n', '<c-f>', '<cmd>FzfLua grep<cr>', {})
|
||||
require("fzf-lua").setup({
|
||||
fzf_bin = "sk",
|
||||
-- fzf_bin = "sk",
|
||||
keymap = {
|
||||
fzf = {
|
||||
-- fzf '--bind=' options
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue