patch 9.1.0425: filetype: purescript files are not recognized Commit: https://github.com/vim/vim/commit/155583a5c317881e60828e3972383436ac197ee8 Author: Riley Bruins <ribr...@hotmail.com> Date: Mon May 20 14:21:53 2024 +0200
patch 9.1.0425: filetype: purescript files are not recognized Problem: filetype: purescript files are not recognized Solution: recognize '*.purs' files as purescript filetype, include basic purescript filetype plugin (Riley Bruins) Reference: https://github.com/purescript/documentation/blob/master/language/Syntax.md#comments closes: #14813 Signed-off-by: Riley Bruins <ribr...@hotmail.com> Signed-off-by: Christian Brabandt <c...@256bit.org> diff --git a/.github/MAINTAINERS b/.github/MAINTAINERS index d6fd02b59..3ae962bbb 100644 --- a/.github/MAINTAINERS +++ b/.github/MAINTAINERS @@ -200,6 +200,7 @@ runtime/ftplugin/postscr.vim @mrdubya runtime/ftplugin/prisma.vim @ribru17 runtime/ftplugin/ps1.vim @heaths runtime/ftplugin/ps1xml.vim @heaths +runtime/ftplugin/purescript.vim @ribru17 runtime/ftplugin/pymanifest.vim @ObserverOfTime runtime/ftplugin/python.vim @tpict runtime/ftplugin/qb64.vim @dkearns diff --git a/runtime/filetype.vim b/runtime/filetype.vim index b52a4c661..bc9046917 100644 --- a/runtime/filetype.vim +++ b/runtime/filetype.vim @@ -1866,6 +1866,9 @@ au BufNewFile,BufRead *.pk setf poke " Protocols au BufNewFile,BufRead */etc/protocols setf protocols +" Purescript +au BufNewFile,BufRead *.purs setf purescript + " PyPA manifest files au BufNewFile,BufRead MANIFEST.in setf pymanifest diff --git a/runtime/ftplugin/purescript.vim b/runtime/ftplugin/purescript.vim new file mode 100644 index 000000000..b3300bb32 --- /dev/null +++ b/runtime/ftplugin/purescript.vim @@ -0,0 +1,14 @@ +" Vim filetype plugin +" Language: purescript +" Maintainer: Riley Bruins <ribr...@gmail.com> +" Last Change: 2024 May 19 + +if exists('b:did_ftplugin') + finish +endif +let b:did_ftplugin = 1 + +setl comments=s1f:{-,mb:\ ,ex:-},:--\ \|,:-- +setl commentstring=--\ %s + +let b:undo_ftplugin = 'setl com< cms<' diff --git a/src/testdir/test_filetype.vim b/src/testdir/test_filetype.vim index fb14c2e23..39327cae8 100644 --- a/src/testdir/test_filetype.vim +++ b/src/testdir/test_filetype.vim @@ -577,6 +577,7 @@ def s:GetFilenameChecks(): dict<list<string>> psl: ['file.psl'], pug: ['file.pug'], puppet: ['file.pp'], + purescript: ['file.purs'], pymanifest: ['MANIFEST.in'], pyret: ['file.arr'], pyrex: ['file.pyx', 'file.pxd'], diff --git a/src/version.c b/src/version.c index b10e50198..7941f8af7 100644 --- a/src/version.c +++ b/src/version.c @@ -704,6 +704,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ +/**/ + 425, /**/ 424, /**/ -- -- You received this message from the "vim_dev" maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php --- You received this message because you are subscribed to the Google Groups "vim_dev" group. To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/vim_dev/E1s929X-00DGOQ-0z%40256bit.org.