From b3530d7c4a102935fa26498a160ee1dc6c1e9c03 Mon Sep 17 00:00:00 2001 From: delta Date: Fri, 4 Jul 2025 00:38:29 +0200 Subject: :3 --- .config/nvim/lua/binds.lua | 54 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 .config/nvim/lua/binds.lua (limited to '.config/nvim/lua/binds.lua') diff --git a/.config/nvim/lua/binds.lua b/.config/nvim/lua/binds.lua new file mode 100644 index 0000000..55da905 --- /dev/null +++ b/.config/nvim/lua/binds.lua @@ -0,0 +1,54 @@ +local map = vim.keymap.set +-- local color_converter = require "color_converter" + +-- toggle nvim-tree +map("n", "t", "NvimTreeToggle") +-- toggle trouble +map("n", "e", "TroubleToggle") +-- undo +map("n", "U", "") + +map("c", "", function() + if vim.fn.pumvisible() == 1 then + return "" + end + return "" +end, { expr = true }) + +map("n", "H", "5h") +map("n", "J", "5j") +map("n", "K", "5k") +map("n", "L", "5l") + +-- disable arrow keys +map("n", "", "") +map("n", "", "") +map("n", "", "") +map("n", "", "") + +map("i", "", "") +map("i", "", "") +map("i", "", "") +map("i", "", "") + +map("n", "h", vim.lsp.buf.hover) +map("n", "gd", vim.lsp.buf.definition) + +map("n", "bp", function() + require('cokeline.mappings').pick("focus") +end, { desc = "Pick a buffer to focus" }) +map("n", "bq", function() + require('cokeline.mappings').pick("close") +end, { desc = "Pick a buffer to close" }) +map("n", "p", function () + require("cokeline.mappings").by_step("switch", -1) +end, { silent = true }) +map("n", "n", function () + require("cokeline.mappings").by_step("switch", 1) +end, { silent = true }) + + +-- local function setup_lsp_keys(_client, buffer) +-- map("d", vim.diagnostic.open_float, "Line diagnostics") +-- +-- end -- cgit v1.2.3