2 ms·
> https://medium.com/really-learn-programming/setting-up-tree-sitter-in-emacs-29-x-a38a9d3a9f2b https://medium.com/really-learn-programming/setting-up-tree-...
by srhtftw 3y ago
> https://medium.com/really-learn-programming/setting-up-tree-sitter-in-emacs-29-x-a38a9d3a9f2b https://medium.com/really-learn-programming/setting-up-tree-...
The author made this story available to Medium members only.
Sign up to read this one for free.
/sigh
- G3rn0ti 3y agoYeah, sorry, I was hastily looking for a tutorial. But I got "c++-ts-mode" working for me now, see my other comment below: https://news.ycombinator.com/item?id=37466899 https://news.ycombinator.com/item?id=37466899 I am still not a competent C++ programmer but this is how your basic tree sitter C++ mode is supposed too look with "C-h m": Minor modes enabled in this buffer: Auto-Save Flycheck Flyspell Font-Lock Yas The major mode is C++// mode defined in c-ts-mode.el: Major mode for editing C++, powered by tree-sitter. This mode is independent from the classic cc-mode.el based ‘c++-mode’, so configuration variables of that mode, like ‘c-basic-offset’, don’t affect this mode. To use tree-sitter C/C++ modes by default, evaluate (add-to-list 'major-mode-remap-alist '(c-mode . c-ts-mode)) (add-to-list 'major-mode-remap-alist '(c++-mode . c++-ts-mode)) (add-to-list 'major-mode-remap-alist '(c-or-c++-mode . c-or-c++-ts-mode))