Skip to content

Commit

Permalink
fix(sources.treesitter): ts source not returning symbols (#189)
Browse files Browse the repository at this point in the history
Bug:    Treesitter source does not return any symbols.
Fix:    Remove use of deprecated `opts.sources.treesitter.name_pattern`
	which is always nil. Use `opts.sources.treesitter.name_regex` to
	get name for the treesitter node.
  • Loading branch information
bekaboo committed Oct 31, 2024
1 parent 28bcb1c commit ef933aa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lua/dropbar/sources/treesitter.lua
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ local function get_node_short_name(node, buf)
.trim(
vim.fn.matchstr(
vim.treesitter.get_node_text(node, buf):gsub('\n', ' '),
configs.opts.sources.treesitter.name_pattern
configs.opts.sources.treesitter.name_regex
)
)
:gsub('%s+', ' ')
Expand Down

0 comments on commit ef933aa

Please sign in to comment.