Currently, select_node only supports a single query which is not ideal when queries are language-dependent. For example, the query in the README is not compatible with python.
This is a simple change that allows passing in a table mapping a filetype to a query to use for that filetype: select_ease.select_node({ queries = { python = query }, direction = "next" }). This is a non-breaking change as query will be used if queries is not passed in. If this PR looks good, I can go ahead and update the README before merging.
Hi @stickperson , thank you for the PR. I didn't had the chance to try out different filetypes when I was developing the plugin. Thank you very much :+1:
Currently,
select_node
only supports a single query which is not ideal when queries are language-dependent. For example, the query in the README is not compatible with python.This is a simple change that allows passing in a table mapping a filetype to a query to use for that filetype:
select_ease.select_node({ queries = { python = query }, direction = "next" })
. This is a non-breaking change asquery
will be used ifqueries
is not passed in. If this PR looks good, I can go ahead and update the README before merging.