A major mode for editing TableGen files.
This mode provides the following features for TableGen source buffers:
- font-locking
- indentation
- structural navigation with tree-sitter objects
- imenu
Emacs 29.1 or above with tree-sitter support is required.
Tree-sitter starter guide: https://git.savannah.gnu.org/cgit/emacs.git/tree/admin/notes/tree-sitter/starter-guide?h=emacs-29
(add-to-list
'treesit-language-source-alist
'(tablegen "https://github.com/amaanq/tree-sitter-tablegen"))
(treesit-install-language-grammar 'tablegen)- Clone this repository
- Add the following to your emacs config
(require "[cloned nverno/tablegen-ts-mode]/tablegen-ts-mode.el")