aboutsummaryrefslogtreecommitdiff
path: root/vim/autoload/Powerline/Functions/fugitive.vim
diff options
context:
space:
mode:
authorBen Beltran <ben@freshout.us>2012-10-19 15:09:38 -0500
committerBen Beltran <ben@freshout.us>2012-10-19 15:09:38 -0500
commit321ecaca67426410316db7db05e6e33809fe1e63 (patch)
tree3811f15c160c6593e84ebfab3994c810a0eeeda5 /vim/autoload/Powerline/Functions/fugitive.vim
parent9041bd938fcce0cf91032c67d529bc21fedeeed3 (diff)
Add powerline
Diffstat (limited to 'vim/autoload/Powerline/Functions/fugitive.vim')
-rw-r--r--vim/autoload/Powerline/Functions/fugitive.vim7
1 files changed, 7 insertions, 0 deletions
diff --git a/vim/autoload/Powerline/Functions/fugitive.vim b/vim/autoload/Powerline/Functions/fugitive.vim
new file mode 100644
index 0000000..bb00131
--- /dev/null
+++ b/vim/autoload/Powerline/Functions/fugitive.vim
@@ -0,0 +1,7 @@
+function! Powerline#Functions#fugitive#GetBranch(symbol) " {{{
+ let ret = fugitive#statusline()
+
+ let ret = substitute(ret, '\c\v\[?GIT\(([a-z0-9\-_\./:]+)\)\]?', a:symbol .' \1', 'g')
+
+ return ret
+endfunction " }}}