0.9.0 • Published 2 months ago

tree-sitter-haxe v0.9.0

Weekly downloads
-
License
MIT
Repository
github
Last release
2 months ago

A tree sitter parser for haxe.

I've only testing this using nvim-treesitter.

Use

Install nvim-treesitter.
Clone this repo, and run tree-sitter generate (you may have to install globally).
Once generated, copy the queries to the nvim-treesitter folder

cp queries/* ~/.vim/BUNDLERPATH/nvim-treesitter/queries/haxe

For example if you're using lazy.nvim run:

cp queries/* ~/.local/share/nvim/lazy/nvim-treesitter/queries/haxe

You may have to create the haxe folder.

Add this snippet to your treesitter config or anywhere in your init.lua:

local parser_config = require "nvim-treesitter.parsers".get_parser_configs()
parser_config.haxe = {
  install_info = {
    url = "https://github.com/vantreeseba/tree-sitter-haxe",
    files = {"src/parser.c"},
    -- optional entries:
    branch = "main",
  },
  filetype = "haxe",
}

Open nvim, and run TSInstallFromGrammer haxe

This should get you running.

I still don't get highlighting...

You might have to add the haxe filetype for neovim to be able to associate the grammar to your files. To do this create the appropriate file with:

touch ~/.nvim/filetype.lua

And add the following content:

vim.filetype.add({
  extension = {
    hx = 'haxe',
  },
})

What it looks like / does so far (the color scheme is of course customizeable through the highlights / etc in vim).

image

0.9.0

2 months ago

0.8.0

2 months ago

0.6.1

6 months ago

0.6.0

6 months ago

0.5.4

9 months ago

0.5.3

9 months ago

0.5.5

9 months ago

0.5.0

9 months ago

0.3.2

10 months ago

0.4.0

9 months ago

0.5.2

9 months ago

0.3.4

10 months ago

0.5.1

9 months ago

0.3.3

10 months ago

0.3.0

2 years ago

0.3.1

1 year ago

0.2.2

2 years ago

0.2.1

2 years ago

0.2.0

2 years ago

0.1.0

3 years ago