Open benknoble opened 2 years ago
The file detection needs to be added as well. The autocmd would go in runtime/filetype.vim, the function in runtime/autoload/dist/ft.vim and tests in src/testdir/test_filetype.vim
I'll submit a PR here with the header additions later today.
Ok, good to know. I should mention that the filetype detection will change somewhat radically; I've opted for an approach that says "Racket is an ecosystem of languages; rather than naïvely try to apply racket
filetype settings to all the languages in the ecosystem, build an ecosystem for many filetype settings." That is, somethings are #lang racket
-like, but others are very much not (#lang datalog
, for example, really needs its own syntax), so they should have filetypes that are not racket
.
Some people have complained and/or don't like it, but there are workarounds and fixes. For example, updating the mapping in this plugin, or extending/overriding it (I need to write docs…).
"Change somewhat radically"—I mean from what currently exists in vim, not from how this plugin currently operates.
Would it be worthwhile just including the racket
filetype to start?
Possibly—that would include the ftplugin, syntax, and indent for racket, but not the filetype detection bit or the related plugins for other #lang
s that have accumulated here.
Linking PR #8
https://github.com/benknoble/vim-racket/pull/10 handles Bram's recent comments on your submission.
Sorry, I always forget to add that boiler plate. Vim9 script does away with the need for that.
Based on a suggestion from @dkearns, it might be worth including this in the vim distribution.
What remains to be done for that to be possible?