Skip to content

Commit

Permalink
Add commentstring for nix file format (#12696)
Browse files Browse the repository at this point in the history
  • Loading branch information
keith committed Aug 11, 2023
1 parent 5fee111 commit d8f9811
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions runtime/ftplugin/nix.vim
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
" Vim filetype plugin
" Language: nix
" Maintainer: Keith Smiley <keithbsmiley@gmail.com>
" Last Change: 2023 Jul 22

" Only do this when not done yet for this buffer
if exists("b:did_ftplugin")
finish
endif

" Don't load another plugin for this buffer
let b:did_ftplugin = 1

let b:undo_ftplugin = "setl commentstring< comments<"

setlocal comments=:#
setlocal commentstring=#\ %s

0 comments on commit d8f9811

Please sign in to comment.