mirror of https://github.com/LazyVim/starter
21 lines
823 B
Lua
21 lines
823 B
Lua
-- Keymaps are automatically loaded on the VeryLazy event
|
|
-- Default keymaps that are always set: https://github.com/LazyVim/LazyVim/blob/main/lua/lazyvim/config/keymaps.lua
|
|
-- Add any additional keymaps here
|
|
local Util = require("lazyvim.util")
|
|
|
|
local function map(mode, lhs, rhs, opts)
|
|
local keys = require("lazy.core.handler").handlers.keys
|
|
---@cast keys LazyKeysHandler
|
|
-- do not create the keymap if a lazy keys handler exists
|
|
if not keys.active[keys.parse({ lhs, mode = mode }).id] then
|
|
opts = opts or {}
|
|
opts.silent = opts.silent ~= false
|
|
vim.keymap.set(mode, lhs, rhs, opts)
|
|
end
|
|
end
|
|
|
|
-- map("n", "<leader>j", "<C-d>", { desc = "Page down" })
|
|
map("n", ",d", "<C-d>", { desc = "Page down" })
|
|
map("n", ",u", "<C-u>", { desc = "Page down" })
|
|
map("n", ",n", ":bNext<cr>", { desc = "Buffer next" })
|