diff options
| author | Teddy Wing | 2014-11-23 15:21:57 -0500 |
|---|---|---|
| committer | Teddy Wing | 2014-11-23 15:21:57 -0500 |
| commit | 3f0a724625c9f3bea3cf6c5123da0fa3154cdb7a (patch) | |
| tree | e90276f0523ac2fc8183c44cb5d46debb3aa5037 | |
| parent | deaa58fdc40cec7590b3a5eb9818a710bde865ba (diff) | |
| download | vim-ls-grep-3f0a724625c9f3bea3cf6c5123da0fa3154cdb7a.tar.bz2 | |
Move `LsGrep` function to autoload/
* Change filename to use an underscore (in order to be able to use it in
the autoload function name)
* Split the function and the command between autoload and plugin files
| -rw-r--r-- | autoload/ls_grep.vim (renamed from ls-grep.vim) | 5 | ||||
| -rw-r--r-- | plugin/ls_grep.vim | 1 |
2 files changed, 2 insertions, 4 deletions
diff --git a/ls-grep.vim b/autoload/ls_grep.vim index 8012dd2..eb4882a 100644 --- a/ls-grep.vim +++ b/autoload/ls_grep.vim @@ -1,4 +1,4 @@ -function! LsGrep(search) +function! ls_grep#LsGrep(search) " Store :ls output redir => ls_output silent ls @@ -10,6 +10,3 @@ function! LsGrep(search) " Display echo ls_output endfunction - - -command! -nargs=1 LsGrep call LsGrep("<args>") diff --git a/plugin/ls_grep.vim b/plugin/ls_grep.vim new file mode 100644 index 0000000..82fc0e9 --- /dev/null +++ b/plugin/ls_grep.vim @@ -0,0 +1 @@ +command! -nargs=1 LsGrep call ls_grep#LsGrep("<args>") |
