Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: allow rules to be treesitter context aware
When a rule is defined with the `:with_context()` method, has a specified filetype, and is operating in a buffer with a treesitter parser attached, the rule will only execute iff the treesitter language at the cursor matches one of the filetypes specified in the initial rule definition. > If there are no specified filetypes, of there is no parser attached to > the current buffer, the rule executes as normal
- Loading branch information
1 parent
9fd4118
commit 3534bfd
Showing
3 changed files
with
34 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters