vim: move keymap for :Lazy to the right place
This commit is contained in:
parent
3d2286141d
commit
af48377e84
2 changed files with 4 additions and 5 deletions
|
@ -104,9 +104,6 @@ local keymap = {
|
||||||
{ '<leader>ll', window.toggle_quickfix, desc = 'Toggle quickfix' },
|
{ '<leader>ll', window.toggle_quickfix, desc = 'Toggle quickfix' },
|
||||||
{ '<localleader>ll', window.toggle_loclist, desc = 'Toggle loclist' },
|
{ '<localleader>ll', window.toggle_loclist, desc = 'Toggle loclist' },
|
||||||
|
|
||||||
-- quickly open lazy.nvim plugin manager
|
|
||||||
{ '<leader>L', '<cmd>Lazy<cr>' },
|
|
||||||
|
|
||||||
-- toggle options
|
-- toggle options
|
||||||
{ '<leader>sn', toggle_number },
|
{ '<leader>sn', toggle_number },
|
||||||
{ '<leader>sr', toggle_relativenumber },
|
{ '<leader>sr', toggle_relativenumber },
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
local M = {}
|
local M = {}
|
||||||
|
|
||||||
local bootstrap_lazy = function(path)
|
local bootstrap = function(path)
|
||||||
if not vim.loop.fs_stat(path) then
|
if not vim.loop.fs_stat(path) then
|
||||||
vim.fn.system {
|
vim.fn.system {
|
||||||
'git',
|
'git',
|
||||||
|
@ -16,12 +16,14 @@ local bootstrap_lazy = function(path)
|
||||||
end
|
end
|
||||||
|
|
||||||
M.setup = function()
|
M.setup = function()
|
||||||
local lazy = bootstrap_lazy(vim.fn.stdpath('data') .. '/lazy/lazy.nvim')
|
local lazy = bootstrap(vim.fn.stdpath('data') .. '/lazy/lazy.nvim')
|
||||||
if not lazy then
|
if not lazy then
|
||||||
vim.notify('Lazy not installed and failed to bootstrap!', vim.log.levels.WARN)
|
vim.notify('Lazy not installed and failed to bootstrap!', vim.log.levels.WARN)
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
|
|
||||||
|
vim.keymap.set('n', '<leader>L', '<cmd>Lazy<cr>')
|
||||||
|
|
||||||
lazy.setup {
|
lazy.setup {
|
||||||
spec = 'fschauen.plugins',
|
spec = 'fschauen.plugins',
|
||||||
dev = {
|
dev = {
|
||||||
|
|
Loading…
Add table
Reference in a new issue