1
0
Fork 0
dotfiles/config/nvim/lua/nifoc/utils/telescope.lua
2021-12-06 23:35:29 +01:00

18 lines
436 B
Lua

local telescope_themes = require('telescope.themes')
local M = {}
M.project_files = function()
local git_opts = telescope_themes.get_ivy()
local ok = pcall(require'telescope.builtin'.git_files, git_opts)
if not ok then
local find_opts = telescope_themes.get_ivy({
find_command = { 'rg', '--files', '--hidden', '-L', '-g', '!.git/*' }
})
require('telescope.builtin').find_files(find_opts)
end
end
return M