News for hackers. Stuff that matters.
Re:Emacs Tree-sitter custom highlighting by lambda_foo on Monday March 03, 2025 @07:04PM (#43248438)
Sure, you will need to write a major mode but honestly it's not that hard to get syntax highlighting working. If you follow something like https://www.masteringemacs.org/article/lets-write-a-treesitt... plus using M-x treesit-explore-mode it took me 1 day to get treesitter support for OCaml, starting from knowing nothing about how Treesitter works with Emacs to a semi-decent highlighting and indentation setup. The indentation was harder to get working, but all up 300 lines of elisp including whitespace and comments.

There are no comments on this comment yet.