Skip to content

Commit ba9a4db

Browse files
authored
Enable tree-sitter queries for Arizona and Erlang syntax highlighting (#2)
- Add used_by configuration to enable both Arizona template and Erlang code highlighting - Update tests to verify parser configuration includes used_by field - Add development commands documentation to README
1 parent e0df34d commit ba9a4db

File tree

3 files changed

+42
-0
lines changed

3 files changed

+42
-0
lines changed

README.md

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,46 @@ require('lspconfig').elp.setup({
7171
})
7272
```
7373

74+
## Development
75+
76+
To test the local plugin during development:
77+
78+
```lua
79+
{
80+
dir = "/path/to/arizona.nvim",
81+
name = "arizona.nvim",
82+
dependencies = {
83+
"nvim-treesitter/nvim-treesitter",
84+
"jmbuhr/otter.nvim",
85+
},
86+
}
87+
```
88+
89+
### Development Commands
90+
91+
```bash
92+
# Install dependencies for local development
93+
make install
94+
95+
# Run tests
96+
make test
97+
98+
# Check code formatting
99+
make lint
100+
101+
# Format code with stylua
102+
make format
103+
104+
# Run health check
105+
make health
106+
107+
# Clean temporary files
108+
make clean
109+
110+
# Run all CI checks (lint + test + health)
111+
make ci
112+
```
113+
74114
## Troubleshooting
75115

76116
Run `:checkhealth arizona` to see what's working and what needs setup.

plugin/arizona.lua

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ local function setup_treesitter()
2727
branch = "main",
2828
},
2929
filetype = "arizona",
30+
used_by = { "arizona", "erlang" },
3031
}
3132
end
3233

tests/arizona_spec.lua

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@ describe("Arizona Framework Plugin", function()
6161
)
6262
assert.same({ "src/parser.c" }, parser_config.install_info.files)
6363
assert.equals("main", parser_config.install_info.branch)
64+
assert.same({ "arizona", "erlang" }, parser_config.used_by)
6465
else
6566
pending("nvim-treesitter not available in test environment")
6667
end

0 commit comments

Comments
 (0)