This repository has been archived on 2025-12-30. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
nvim-old/lua/haelnorr/lazy/telescope.lua

32 lines
836 B
Lua

return {
"nvim-telescope/telescope.nvim",
tag = "0.1.5",
dependencies = {
"nvim-lua/plenary.nvim",
},
config = function()
require("telescope").setup({
defaults = { layout_strategy = "vertical" },
})
local builtin = require("telescope.builtin")
vim.keymap.set("n", "<leader>pf", builtin.find_files, {})
vim.keymap.set("n", "<C-p>", builtin.git_files, {})
vim.keymap.set("n", "<leader>pws", function()
local word = vim.fn.expand("<cword>")
builtin.grep_string({ search = word })
end)
vim.keymap.set("n", "<leader>pWs", function()
local word = vim.fn.expand("<cWORD>")
builtin.grep_string({ search = word })
end)
vim.keymap.set("n", "<leader>ps", function()
builtin.grep_string({ search = vim.fn.input("Grep > ") })
end)
vim.keymap.set("n", "<leader>vh", builtin.help_tags, {})
end,
}