aboutsummaryrefslogtreecommitdiff
path: root/vim/bundle/vim-addon-mw-utils/autoload/glob.vim
diff options
context:
space:
mode:
authorKarel Kočí <cynerd@email.cz>2016-06-30 16:11:56 +0200
committerKarel Kočí <cynerd@email.cz>2016-06-30 16:11:56 +0200
commit9931e0888b2419326ae10ebbfae532261c5c125f (patch)
tree7504be5daccbb7b7d1ea396754de47b11ed790e5 /vim/bundle/vim-addon-mw-utils/autoload/glob.vim
parente573b3020c032400eed60b649a2cbf55266e6bb0 (diff)
downloadmyconfigs-9931e0888b2419326ae10ebbfae532261c5c125f.tar.gz
myconfigs-9931e0888b2419326ae10ebbfae532261c5c125f.tar.bz2
myconfigs-9931e0888b2419326ae10ebbfae532261c5c125f.zip
Fix submodules
Diffstat (limited to 'vim/bundle/vim-addon-mw-utils/autoload/glob.vim')
m---------vim/bundle/vim-addon-mw-utils0
-rw-r--r--vim/bundle/vim-addon-mw-utils/autoload/glob.vim27
2 files changed, 0 insertions, 27 deletions
diff --git a/vim/bundle/vim-addon-mw-utils b/vim/bundle/vim-addon-mw-utils
new file mode 160000
+Subproject 0c5612fa31ee434ba055e21c76f456244b3b510
diff --git a/vim/bundle/vim-addon-mw-utils/autoload/glob.vim b/vim/bundle/vim-addon-mw-utils/autoload/glob.vim
deleted file mode 100644
index 9a0f79a..0000000
--- a/vim/bundle/vim-addon-mw-utils/autoload/glob.vim
+++ /dev/null
@@ -1,27 +0,0 @@
-exec vam#DefineAndBind('s:c','g:glob_like', '{}')
-
-" ignore vcs stuff, Don't think you want those..
-let s:c['regex_ignore_directory'] = '\<\%([_.]darcs\|\.git\|.svn\|.hg\|.cvs\|.bzr\)\>'
-let s:c['glob_cache'] = get(s:c, 'glob_cache', {})
-let s:glob_cache = s:c['glob_cache']
-
-fun! glob#Glob(pattern, ...)
- let pattern = a:pattern
- if pattern[0] == '~'
- let pattern = $HOME.pattern[1:]
- endif
- let opts = a:0 > 0 ? a:1 : {}
- " never cache current directory. You're very likely to edit files in it.
-
- let c = getcwd()
- let cachable = get(opts, 'cachable', 0) && pattern[:len(c)-1] != c
- if cachable && has_key(s:glob_cache, pattern)
- return s:glob_cache[pattern]
- endif
-
- " FIXME: don't recurse into \.git directory (thus reimplement glob in vimL!)
- let r = filter(split(glob(pattern),"\n"),'v:val !~ '.string(s:c['regex_ignore_directory']))
- if cachable | let s:glob_cache[pattern] = r | endif
- return r
-endf
-