Closed jacobrreed closed 8 months ago
It's --no-ignore-vcs
.
The rest looks good/works.
Try this minimal config (save as min.lua
under some tmp dir and launch neovim with nvim -nu min.lua
)
local root = vim.fn.fnamemodify("./.repro", ":p")
-- set stdpaths to use .repro
for _, name in ipairs({ "config", "data", "state", "cache" }) do
vim.env[("XDG_%s_HOME"):format(name:upper())] = root .. "/" .. name
end
-- bootstrap lazy
local lazypath = root .. "/plugins/lazy.nvim"
if not vim.loop.fs_stat(lazypath) then
vim.fn.system({
"git",
"clone",
"--filter=blob:none",
"https://github.com/folke/lazy.nvim.git",
lazypath,
})
end
vim.opt.runtimepath:prepend(lazypath)
-- install plugins
local plugins = {
{
"nvim-telescope/telescope.nvim",
tag = "0.1.5",
dependencies = {
"nvim-lua/plenary.nvim",
"nvim-tree/nvim-web-devicons",
},
config = function()
require("telescope").setup({
pickers = {
find_files = {
find_command = {
"rg",
"--files",
"--hidden",
"--no-ignore-vcs",
"-g",
"!**/.git/*",
"-g",
"!**/node_modules/*",
"-g", "!**/.repro/*", -- just to hide .repro rtp
},
},
},
})
end,
},
}
require("lazy").setup(plugins, {
root = root .. "/plugins",
})
Description
I am trying to make the find_files command search all files, including items in .gitignore, but still hide all .git folders and node_modules. I have the following config
But no hidden files show up still
Neovim version
Operating system and version
MacOS 14.2.1
Telescope version / branch / rev
0.1.5
checkhealth telescope
Steps to reproduce
Open a folder with .git folder and node_modules folder, add a file to .gitignore like
dist/
, then in dist folder add a file. Try searching for it using Telescope find_files, the file inside of dist wont showExpected behavior
I expect the above to work, could be user error
Actual behavior
Still doesnt show any hidden files at all, all .gitignored files are still hidden
Minimal config