Help needed in installing telescope #1340
Answered
by
praveshishere
praveshishere
asked this question in
Q&A
-
I am trying to install https://github.com/nvim-telescope/telescope-fzf-native.nvim
and
and
what I am not sure about is where to put these setup instructions for telescope require('telescope').setup {
extensions = {
fzf = {
fuzzy = true, -- false will only do exact matching
override_generic_sorter = true, -- override the generic sorter
override_file_sorter = true, -- override the file sorter
case_mode = "smart_case", -- or "ignore_case" or "respect_case"
-- the default case_mode is "smart_case"
}
}
}
require('telescope').load_extension('fzf') I am new to vim, please suggest if any ideas |
Beta Was this translation helpful? Give feedback.
Answered by
praveshishere
Feb 28, 2024
Replies: 1 comment
-
Found the solution, the config property in plugin config is used for running setup functions here is my example return {
{
"nvim-treesitter/nvim-treesitter",
build = ":TSUpdate",
config = function ()
local configs = require("nvim-treesitter.configs")
configs.setup({
ensure_installed = { "c", "lua", "vim", "vimdoc", "query", "elixir", "heex", "javascript", "html" },
sync_install = false,
highlight = { enable = true },
indent = { enable = true },
})
end
},
{
"nvim-telescope/telescope.nvim",
tag = '0.1.5',
opts = { extensions_list = { "fzf" } },
dependencies = {
{ 'nvim-lua/plenary.nvim' },
{ "nvim-telescope/telescope-fzf-native.nvim", build = "make" },
},
config = function()
require('telescope').setup {
extensions = {
fzf = {
fuzzy = true, -- false will only do exact matching
override_generic_sorter = true, -- override the generic sorter
override_file_sorter = true, -- override the file sorter
case_mode = "smart_case", -- or "ignore_case" or "respect_case"
-- the default case_mode is "smart_case"
}
}
}
require('telescope').load_extension('fzf')
local builtin = require('telescope.builtin')
vim.keymap.set('n', '<leader>ff', builtin.find_files, {})
vim.keymap.set('n', '<leader>fg', builtin.live_grep, {})
vim.keymap.set('n', '<leader>fb', builtin.buffers, {})
vim.keymap.set('n', '<leader>fh', builtin.help_tags, {})
end,
}
} |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
praveshishere
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Found the solution, the config property in plugin config is used for running setup functions
here is my example