Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Add relative() and absolute() aliases

The existing methods name() and path() are arbitrary.
  • Loading branch information...
commit fd4cadbd944badba8ebf6b324aac367e78059461 1 parent 1360775
@tpope authored
Showing with 9 additions and 1 deletion.
  1. +9 −1 plugin/rake.vim
View
10 plugin/rake.vim
@@ -246,7 +246,15 @@ function! s:buffer_path() dict abort
return s:shellslash(bufname == '' ? '' : fnamemodify(bufname,':p'))
endfunction
-call s:add_methods('buffer',['getvar','setvar','getline','project','name','path'])
+function! s:buffer_relative() dict abort
+ return self.name()
+endfunction
+
+function! s:buffer_absolute() dict abort
+ return self.path()
+endfunction
+
+call s:add_methods('buffer',['getvar','setvar','getline','project','name','path','relative','absolute'])
" }}}1
" Rake {{{1
Please sign in to comment.
Something went wrong with that request. Please try again.