Add further customizations
This commit is contained in:
parent
960d0fd871
commit
a865ebf4eb
39
init.lua
39
init.lua
|
@ -222,7 +222,27 @@ require('lazy').setup({
|
||||||
build = "cd app && npm install",
|
build = "cd app && npm install",
|
||||||
init = function() vim.g.mkdp_filetypes = { "markdown" } end,
|
init = function() vim.g.mkdp_filetypes = { "markdown" } end,
|
||||||
},
|
},
|
||||||
|
-- show notifications etc in a nice area
|
||||||
|
{'folke/noice.nvim',
|
||||||
|
event = 'VeryLazy',
|
||||||
|
opts = {
|
||||||
|
-- add any options here
|
||||||
|
},
|
||||||
|
dependencies = {
|
||||||
|
-- if you lazy-load any plugin below, make sure to add proper `module="..."` entries
|
||||||
|
'MunifTanjim/nui.nvim',
|
||||||
|
-- OPTIONAL:
|
||||||
|
-- `nvim-notify` is only needed, if you want to use the notification view.
|
||||||
|
-- If not available, we use `mini` as the fallback
|
||||||
|
'rcarriga/nvim-notify',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
-- tmux vim keybindings
|
||||||
'christoomey/vim-tmux-navigator',
|
'christoomey/vim-tmux-navigator',
|
||||||
|
-- databse connections from within vim using DBGUI and DB
|
||||||
|
'tpope/vim-dadbod',
|
||||||
|
'kristijanhusak/vim-dadbod-ui',
|
||||||
|
'kristijanhusak/vim-dadbod-completion',
|
||||||
|
|
||||||
-- NOTE: Next Step on Your Neovim Journey: Add/Configure additional "plugins" for kickstart
|
-- NOTE: Next Step on Your Neovim Journey: Add/Configure additional "plugins" for kickstart
|
||||||
-- These are some example plugins that I've included in the kickstart repository.
|
-- These are some example plugins that I've included in the kickstart repository.
|
||||||
|
@ -336,6 +356,13 @@ require('telescope').setup {
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
pickers = {
|
||||||
|
live_grep = {
|
||||||
|
additional_args = function(opts)
|
||||||
|
return {"--hidden"}
|
||||||
|
end
|
||||||
|
},
|
||||||
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
-- Enable telescope fzf native, if installed
|
-- Enable telescope fzf native, if installed
|
||||||
|
@ -353,11 +380,12 @@ vim.keymap.set('n', '<leader>/', function()
|
||||||
end, { desc = '[/] Fuzzily search in current buffer' })
|
end, { desc = '[/] Fuzzily search in current buffer' })
|
||||||
|
|
||||||
vim.keymap.set('n', '<leader>gf', require('telescope.builtin').git_files, { desc = 'Search [G]it [F]iles' })
|
vim.keymap.set('n', '<leader>gf', require('telescope.builtin').git_files, { desc = 'Search [G]it [F]iles' })
|
||||||
vim.keymap.set('n', '<leader>sf', require('telescope.builtin').find_files, { desc = '[S]earch [F]iles' })
|
|
||||||
vim.keymap.set('n', '<leader>sh', require('telescope.builtin').help_tags, { desc = '[S]earch [H]elp' })
|
vim.keymap.set('n', '<leader>sh', require('telescope.builtin').help_tags, { desc = '[S]earch [H]elp' })
|
||||||
vim.keymap.set('n', '<leader>sw', require('telescope.builtin').grep_string, { desc = '[S]earch current [W]ord' })
|
vim.keymap.set('n', '<leader>sw', require('telescope.builtin').grep_string, { desc = '[S]earch current [W]ord' })
|
||||||
vim.keymap.set('n', '<leader>sg', require('telescope.builtin').live_grep, { desc = '[S]earch by [G]rep' })
|
vim.keymap.set('n', '<leader>sg', require('telescope.builtin').live_grep, { desc = '[S]earch by [G]rep' })
|
||||||
vim.keymap.set('n', '<leader>sd', require('telescope.builtin').diagnostics, { desc = '[S]earch [D]iagnostics' })
|
vim.keymap.set('n', '<leader>sd', require('telescope.builtin').diagnostics, { desc = '[S]earch [D]iagnostics' })
|
||||||
|
vim.keymap.set('n', '<leader>sfn', require('telescope.builtin').find_files, { desc = '[S]earch [F]iles [N]o Hidden' })
|
||||||
|
vim.keymap.set('n', '<leader>sfh', '<Cmd>Telescope find_files hidden=true no_ignore=true<Cr>', { desc = '[S]earch [F]iles [H]idden' })
|
||||||
|
|
||||||
-- [[ Configure Treesitter ]]
|
-- [[ Configure Treesitter ]]
|
||||||
-- See `:help nvim-treesitter`
|
-- See `:help nvim-treesitter`
|
||||||
|
@ -570,6 +598,7 @@ cmp.setup {
|
||||||
sources = {
|
sources = {
|
||||||
{ name = 'nvim_lsp' },
|
{ name = 'nvim_lsp' },
|
||||||
{ name = 'luasnip' },
|
{ name = 'luasnip' },
|
||||||
|
{ name = 'vim-dadbod-completion' },
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -592,3 +621,11 @@ wilder.setup({modes = {':', '/', '?'}})
|
||||||
-- Unless you are still migrating, remove the deprecated commands from v1.x
|
-- Unless you are still migrating, remove the deprecated commands from v1.x
|
||||||
vim.cmd([[ let g:neo_tree_remove_legacy_commands = 1 ]])
|
vim.cmd([[ let g:neo_tree_remove_legacy_commands = 1 ]])
|
||||||
|
|
||||||
|
-- neo_tree
|
||||||
|
vim.keymap.set('n', '<leader>f', '<Cmd>Neotree toggle<Cr>', { desc = 'Toggle NeoTree' })
|
||||||
|
|
||||||
|
-- database
|
||||||
|
vim.keymap.set('n', '<leader>nu', '<Cmd>DBUIToggle<Cr>', { desc = 'Toggle UI' })
|
||||||
|
vim.keymap.set('n', '<leader>nf', '<Cmd>DBUIFindBuffer<Cr>', { desc = 'Find buffer' })
|
||||||
|
vim.keymap.set('n', '<leader>nr', '<Cmd>DBUIRenameBuffer<Cr>', { desc = 'Rename buffer' })
|
||||||
|
vim.keymap.set('n', '<leader>nq', '<Cmd>DBUILastQueryInfo<Cr>', { desc = 'Last query info' })
|
||||||
|
|
Loading…
Reference in New Issue