From 1834c083aa436d59713b0054566e06648d67ac1e Mon Sep 17 00:00:00 2001 From: Tom Ryder Date: Mon, 30 Oct 2017 19:11:22 +1300 Subject: Apply name conventions, scoping to Vim identifiers The Google VimScript Style Guide says : >In general, use plugin-names-like-this, FunctionNamesLikeThis, >CommandNamesLikeThis, augroup_names_like_this, >variable_names_like_this. Adjusted variable, function, and `augroup` names accordingly, including setting script scope for some of the functions and their calls (`s:` and `` prefixes). Initially I tried using `prefix#`, but it turns out that this is a namespacing contention for publically callable functions like `pathogen#infect`, and none of these functions need to be publically callable. --- vim/ftdetect/csv.vim | 2 +- vim/ftdetect/muttrc.vim | 2 +- vim/ftdetect/sh.vim | 2 +- vim/ftdetect/tsv.vim | 2 +- vim/ftdetect/xdefaults.vim | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) (limited to 'vim/ftdetect') diff --git a/vim/ftdetect/csv.vim b/vim/ftdetect/csv.vim index 727077a0..e5a38e10 100644 --- a/vim/ftdetect/csv.vim +++ b/vim/ftdetect/csv.vim @@ -1,5 +1,5 @@ " Add automatic commands to detect CSV files -augroup dfcsv +augroup dotfiles_ftdetect_csv autocmd! autocmd BufNewFile,BufRead \ *.csv diff --git a/vim/ftdetect/muttrc.vim b/vim/ftdetect/muttrc.vim index 832d0c1f..0f625f2b 100644 --- a/vim/ftdetect/muttrc.vim +++ b/vim/ftdetect/muttrc.vim @@ -1,5 +1,5 @@ " Add automatic commands to detect .muttrc files -augroup dfmuttrc +augroup dotfiles_ftdetect_muttrc autocmd! autocmd BufNewFile,BufRead \ **/.dotfiles/mutt/muttrc.d/*.rc,**/.muttrc.d/*.rc diff --git a/vim/ftdetect/sh.vim b/vim/ftdetect/sh.vim index 92aa2a0c..3df9c3ce 100644 --- a/vim/ftdetect/sh.vim +++ b/vim/ftdetect/sh.vim @@ -1,5 +1,5 @@ " Add automatic commands to choose shell flavours based on filename pattern -augroup dfsh +augroup dotfiles_ftdetect_sh autocmd! " Names/paths of things that are Bash shell script diff --git a/vim/ftdetect/tsv.vim b/vim/ftdetect/tsv.vim index af544a94..673721f5 100644 --- a/vim/ftdetect/tsv.vim +++ b/vim/ftdetect/tsv.vim @@ -1,5 +1,5 @@ " Add automatic commands to detect TSV files -augroup dftsv +augroup dotfiles_ftdetect_tsv autocmd! autocmd BufNewFile,BufRead \ *.tsv diff --git a/vim/ftdetect/xdefaults.vim b/vim/ftdetect/xdefaults.vim index 098ded56..1529e5c9 100644 --- a/vim/ftdetect/xdefaults.vim +++ b/vim/ftdetect/xdefaults.vim @@ -1,5 +1,5 @@ " Add automatic commands to find Xresources subfiles -augroup dfxdefaults +augroup dotfiles_ftdetect_xdefaults autocmd! autocmd BufNewFile,BufRead \ **/.Xresources.d/* -- cgit v1.2.3