aboutsummaryrefslogtreecommitdiffstats
path: root/nvim/lua
diff options
context:
space:
mode:
authorJP Appel <jeanpierre.appel01@gmail.com>2025-03-31 11:24:03 -0400
committerJP Appel <jeanpierre.appel01@gmail.com>2025-03-31 11:24:03 -0400
commit2b6715b44044d6d0817ae530a9d32a3571c26223 (patch)
tree782b4616545e1d60ccc7c2bb5fa977f2495ebc53 /nvim/lua
parenta083c8ec55e5101269099de399d621dc03a9dea2 (diff)
Change telescope keybinds
Diffstat (limited to 'nvim/lua')
-rw-r--r--nvim/lua/keymap.lua3
-rw-r--r--nvim/lua/plugins/lsp.lua2
-rw-r--r--nvim/lua/plugins/telescope.lua18
-rw-r--r--nvim/lua/plugins/todos.lua2
4 files changed, 14 insertions, 11 deletions
diff --git a/nvim/lua/keymap.lua b/nvim/lua/keymap.lua
index 56f5491..5c6e39a 100644
--- a/nvim/lua/keymap.lua
+++ b/nvim/lua/keymap.lua
@@ -2,6 +2,9 @@ local shared = require('shared')
local M = {}
+-- disable ctrl-f to work nicer with telescope binds
+vim.keymap.set('n', '<C-f>', '<NOP>')
+
vim.keymap.set('n', 'gf', function() shared.cmd_pcall(':e <cfile>') end, { noremap = true })
vim.keymap.set('n', "<Leader>q", function()
if vim.o.ft == "qf" then
diff --git a/nvim/lua/plugins/lsp.lua b/nvim/lua/plugins/lsp.lua
index 418f03b..7a26f35 100644
--- a/nvim/lua/plugins/lsp.lua
+++ b/nvim/lua/plugins/lsp.lua
@@ -49,7 +49,7 @@ local lspconfig = {
desc = "Rename symbol"
},
{
- '<C-f>',
+ '<leader>f',
function()
vim.lsp.buf.format()
end,
diff --git a/nvim/lua/plugins/telescope.lua b/nvim/lua/plugins/telescope.lua
index 77fc893..731c509 100644
--- a/nvim/lua/plugins/telescope.lua
+++ b/nvim/lua/plugins/telescope.lua
@@ -7,7 +7,7 @@ return {
cmd = 'Telescope',
keys = {
{
- "<leader>ff",
+ "<C-f>f",
function()
local builtin = require("telescope.builtin")
builtin.find_files()
@@ -15,32 +15,32 @@ return {
desc = "Search for files (respcting .gitignore) using Telescope"
},
{
- "<leader>fF",
+ "<C-f>F",
function()
require("telescope.builtin").find_files({ hidden = true, no_ignore_parent = true })
end,
desc = "Search for files (including hidden) using Telescope"
},
{
- "<leader>fb",
+ "<C-f>b",
function()
require("telescope.builtin").buffers()
end,
desc = "Search for open buffers using Telescope"
},
- { "<leader>fg", function()
+ { "<C-f>g", function()
require("telescope.builtin").live_grep()
end
},
{
- "<leader>fm",
+ "<C-f>m",
function()
require("telescope.builtin").marks()
end,
desc = "Search marks using telescope"
},
{
- "<leader>fq",
+ "<C-f>q",
function()
local themes = require("telescope.themes")
require("telescope.builtin").quickfix(themes.get_ivy({}))
@@ -48,7 +48,7 @@ return {
desc = "Search in the the quickfix buffer using Telescope"
},
{
- "<leader>fl",
+ "<C-f>l",
function()
local themes = require("telescope.themes")
require("telescope.builtin").loclist(themes.get_ivy({}))
@@ -56,7 +56,7 @@ return {
desc = "Search within a location list using Telescope"
},
{
- "<leader>fd",
+ "<C-f>d",
function()
local themes = require("telescope.themes")
require("telescope.builtin").diagnostics(themes.get_ivy({}))
@@ -64,7 +64,7 @@ return {
desc = "Search through diagnostics using Telescope"
},
{
- "<leader>fr",
+ "<C-f>r",
function()
-- TODO: if lsp supports reference provider and lsp is attached
-- [telescope.builtin.lsp_*]: server does not support referencesProvider
diff --git a/nvim/lua/plugins/todos.lua b/nvim/lua/plugins/todos.lua
index 1e5d4ad..e30547a 100644
--- a/nvim/lua/plugins/todos.lua
+++ b/nvim/lua/plugins/todos.lua
@@ -83,7 +83,7 @@ return {
desc = "Previous todo comment"
},
{
- "<leader>ft",
+ "<C-f>t",
"<cmd>TodoTelescope<cr>",
mode = 'n',
desc = "Open Todos in quickfix list"