Skip to content

Commit 9fbb655

Browse files
committed
👽 Pass nodes to jq
1 parent 3e19627 commit 9fbb655

3 files changed

Lines changed: 5 additions & 4 deletions

File tree

pyproject.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
# https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html
22
[project]
33
name = "autotools-language-server"
4-
version = "0.1.2"
4+
version = "0.1.3"
55
description = "Language server for configure.ac"
66
readme = "README.md"
77
# type_a | type_b
88
requires-python = ">= 3.10"
99
license = "GPL-3.0-or-later"
1010
keywords = ["autotools", "language server"]
1111
dependencies = [
12-
"lsp-tree-sitter>=0.2.9",
12+
"lsp-tree-sitter>=0.2.13",
1313
"tree-sitter-autoconf>=0.0.1",
1414
]
1515

src/autotools_language_server/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@
22
`importlib.metadata.version() <https://docs.python.org/3/library/importlib.metadata.html#distribution-versions>`_.
33
"""
44

5-
__version__ = "0.1.2"
5+
__version__ = "0.1.3"

src/autotools_language_server/assets/jq/main.jq

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
1+
$nodes[0].type as $type |
12
if $type == "macro_name" or ($complete and $type == "code") then
23
.properties
34
else
45
{}
56
end | to_entries[] |
6-
if .key | (if $complete then startswith($text) else . == $text end) then
7+
if .key | ($nodes[0].text as $text | if $complete then startswith($text) else . == $text end) then
78
{
89
label: .key,
910
insert_text: .key,

0 commit comments

Comments
 (0)