Skip to content

Setting up ignore in telescope pickers #4

@cathyprime

Description

@cathyprime

Telescope pickers take options in most cases, you can access the documentation of the most used one (find_files) by typing :h telescope.builtin.find_files()
docs on github:

https://github.com/nvim-telescope/telescope.nvim/blob/175178e3889c13a840f036d464aee2d145157b9e/doc/telescope.txt#L917-L954

here is an example of how to do it:

https://github.com/Cathyprime/nvim-dots/blob/34f818bd05476bb89e823993b9b4c87b057c7917/lua/cathy/plugin/telescope.lua#L3-L8

as you can see the docs don't say that you can pass file_ignore_patterns to pickers themselves, but it is allowed:
https://github.com/nvim-telescope/telescope.nvim/blob/175178e3889c13a840f036d464aee2d145157b9e/lua/telescope/pickers.lua#L301

as a fun fact there is a way to open either find_files or git_files depending on if you are in a git project, I even made in my config Kappa

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions