From f83351863e221e448ab1fb1d149a13e6c2d5466b Mon Sep 17 00:00:00 2001
From: Chris Coley <chris@codingallnight.com>
Date: Tue, 17 Sep 2019 14:03:34 -0700
Subject: [PATCH] Replace the DNS FileType specific settings with a more robust
 plugin

---
 vim/ftplugin/bindzone.vim | 1 +
 vim/ftplugin/dns.vim      | 2 ++
 vim/ftplugin/named.vim    | 2 ++
 vimrc                     | 4 ----
 4 files changed, 5 insertions(+), 4 deletions(-)
 create mode 100644 vim/ftplugin/bindzone.vim
 create mode 100644 vim/ftplugin/dns.vim
 create mode 100644 vim/ftplugin/named.vim

diff --git a/vim/ftplugin/bindzone.vim b/vim/ftplugin/bindzone.vim
new file mode 100644
index 0000000..e1bce48
--- /dev/null
+++ b/vim/ftplugin/bindzone.vim
@@ -0,0 +1 @@
+let b:ml_commentstring = '; %s'
diff --git a/vim/ftplugin/dns.vim b/vim/ftplugin/dns.vim
new file mode 100644
index 0000000..82bfff3
--- /dev/null
+++ b/vim/ftplugin/dns.vim
@@ -0,0 +1,2 @@
+" This has been replaced by the bindzone filetype
+:runtime! ftplugin/bindzone.vim
diff --git a/vim/ftplugin/named.vim b/vim/ftplugin/named.vim
new file mode 100644
index 0000000..95db5c0
--- /dev/null
+++ b/vim/ftplugin/named.vim
@@ -0,0 +1,2 @@
+" Set the modeline to use a single line comment
+let b:ml_commentstring = '// %s'
diff --git a/vimrc b/vimrc
index 50217c6..825b4f4 100644
--- a/vimrc
+++ b/vimrc
@@ -93,10 +93,6 @@ function! AppendModeline()
 endfunction
 
 
-" Filetype specific settings
-autocmd FileType dns setlocal commentstring=;\ %s
-
-
 " Map numpad keys in insert and command-line mode
 "noremap! <Esc>Oq 1
 "noremap! <Esc>Or 2
-- 
GitLab