Skip to content

Commit 5455092

Browse files
docs: edit installation guide about tree-sitter-http
1 parent c4517cc commit 5455092

File tree

1 file changed

+10
-4
lines changed

1 file changed

+10
-4
lines changed

README.md

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -49,26 +49,32 @@ CLI.
4949

5050
- Neovim >= 0.10.1
5151
- `curl`
52-
- [tree-sitter-http] (`scm` version)
52+
- [tree-sitter-http] (if you use `lazy.nvim`)
5353

5454
### [rocks.nvim](https://github.com/nvim-neorocks/rocks.nvim) (recommended)
5555

5656
```vim
5757
:Rocks install rest.nvim
58-
:Rocks install tree-sitter-http dev
5958
```
6059

6160
### [lazy.nvim](https://github.com/folke/lazy.nvim)
6261

6362
```lua
6463
{
6564
"rest-nvim/rest.nvim",
65+
dependencies = {
66+
"nvim-treesitter/nvim-treesitter",
67+
opts = function (_, opts)
68+
opts.ensure_installed = opts.ensure_installed or {}
69+
table.insert(opts.ensure_installed, "http")
70+
end,
71+
}
6672
}
6773
```
6874

6975
> [!NOTE]
70-
> you also need to install latest [tree-sitter-http] parser using
71-
> `:TSInstall http`
76+
> You also need to install latest [tree-sitter-http] parser using
77+
> `:TSInstall http` if you are using `lazy.nvim`
7278
7379
<!-- TODO: I'm not sure packer supporst tree-sitter installation via luarocks -->
7480
<!-- ### [packer.nvim](https://github.com/wbthomason/packer.nvim) -->

0 commit comments

Comments
 (0)