gpt4 book ai didi

neovim - 使用 telescope.nvim 时如何在搜索结果中包含特定的隐藏文件/文件夹?

转载 作者:行者123 更新时间:2023-12-05 02:30:38 31 4
gpt4 key购买 nike

我使用 neovim 和 Telescope 作为查找器(find_files、live_grep、file_browser),默认情况下 Telescope 忽略隐藏文件和包含在 .gitignore 中的文件——我如何添加异常(exception)(例如 .gitlab-ci 文件/文件夹)到这个列表?所以 Telescope 仍然会忽略除 .gitlab-ci 文件/文件夹之外的隐藏文件?

最佳答案

像那样使用默认过滤器忽略模式

telescope.setup {
....
defaults = {
....
file_ignore_patterns = {
"node_modules", "build", "dist", "yarn.lock"
},
}
}

我知道你可以在某人的 vimrc 文件或 telescope docs 中找到它.但可能会帮助一些新手。

关于neovim - 使用 telescope.nvim 时如何在搜索结果中包含特定的隐藏文件/文件夹?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/71809098/

31 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com