How to filter with itemgroup? #389
-
I want to use legendary as folder action select, so I can select folder from telescope and use legendary. So I write the script as following: return function (cwd)
legendary.funcs({
itemgroup = 'Folder action',
funcs = {},
})
legendary.find({
select_prompt = 'Folder action under: ' .. cwd,
filters = {
--- how to write this??
}
})
end how to write the filters so that only everything under 'Folder action' item group shown? I have looked over the docs, nothing found. |
Beta Was this translation helpful? Give feedback.
Answered by
mrjones2014
Jul 6, 2023
Replies: 1 comment
-
A filter is just a function with the signature |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
towry
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
A filter is just a function with the signature
fun(item): bool
, however there is currently no way to start the finder with an itemgroup already selected. That will require some plugin changes, but it's doable.