Skip to content
Discussion options

You must be logged in to vote

drowned out

Yeah, I know that feeling.

search for a specific folder

-- Use `opts.picker.sources.explorer`
Snacks.explorer({
  toggles = {
    search_dir = "D",
  },
  transform = function(item, ctx)
    local is_searching = ctx.picker.input.filter.meta.searching
    if is_searching and ctx.picker.opts.search_dir then
      return item.dir or false
    end
  end,
  win = {
    input = {
      keys = {
        -- NOTE: This key was previously used for the "inspect" action
        ["<M-d>"] = { "toggle_search_dir", mode = { "i", "n" } },
      },
    },
    list = {
      keys = {
        ["<M-d>"] = "toggle_search_dir",
      },
    },
  },
})

split the explorer

You cannot split it, b…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@vvilhelmsen
Comment options

Answer selected by vvilhelmsen
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants