neovim

Neovim text editor
git clone https://git.dasho.dev/neovim.git
Log | Files | Refs | README

r.vim (1071B)


      1 " Vim filetype plugin file
      2 " Language:		R
      3 " Maintainer:		This runtime file is looking for a new maintainer.
      4 " Former Maintainer:	Jakson Alves de Aquino <jalvesaq@gmail.com>
      5 " Former Repository:	https://github.com/jalvesaq/R-Vim-runtime
      6 " Last Change:		2024 Feb 28 by Vim Project
      7 
      8 " Only do this when not yet done for this buffer
      9 if exists("b:did_ftplugin")
     10  finish
     11 endif
     12 
     13 " Don't load another plugin for this buffer
     14 let b:did_ftplugin = 1
     15 
     16 let s:cpo_save = &cpo
     17 set cpo&vim
     18 
     19 setlocal iskeyword=@,48-57,_,.
     20 setlocal formatoptions-=t
     21 setlocal commentstring=#\ %s
     22 setlocal comments=:#',:###,:##,:#
     23 
     24 if (has("gui_win32") || has("gui_gtk")) && !exists("b:browsefilter")
     25  let b:browsefilter = "R Source Files (*.R)\t*.R\n" .
     26        \ "Files that include R (*.Rnw, *.Rd, *.Rmd, *.Rrst, *.qmd)\t*.Rnw;*.Rd;*.Rmd;*.Rrst;*.qmd\n"
     27  if has("win32")
     28    let b:browsefilter .= "All Files (*.*)\t*\n"
     29  else
     30    let b:browsefilter .= "All Files (*)\t*\n"
     31  endif
     32 endif
     33 
     34 let b:undo_ftplugin = "setl cms< com< fo< isk< | unlet! b:browsefilter"
     35 
     36 let &cpo = s:cpo_save
     37 unlet s:cpo_save