mirror of
https://github.com/tpope/vim-fugitive.git
synced 2025-11-13 22:03:51 -05:00
Fix function reference
This commit is contained in:
@@ -179,10 +179,10 @@ function! fugitive#RemoteUrl(...) abort
|
|||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! s:recall() abort
|
function! s:recall() abort
|
||||||
let rev = s:sub(s:buffer().rev(), '^/', '')
|
let rev = s:sub(fugitive#buffer().rev(), '^/', '')
|
||||||
if rev ==# ':'
|
if rev ==# ':'
|
||||||
return matchstr(getline('.'),'^.\=\t\%([[:alpha:] ]\+: *\)\=\zs.\{-\}\ze\%( ([^()[:digit:]]\+)\)\=$\|^\d\{6} \x\{40\} \d\t\zs.*')
|
return matchstr(getline('.'),'^.\=\t\%([[:alpha:] ]\+: *\)\=\zs.\{-\}\ze\%( ([^()[:digit:]]\+)\)\=$\|^\d\{6} \x\{40\} \d\t\zs.*')
|
||||||
elseif s:buffer().type('tree')
|
elseif fugitive#buffer().type('tree')
|
||||||
let file = matchstr(getline('.'), '\t\zs.*')
|
let file = matchstr(getline('.'), '\t\zs.*')
|
||||||
if empty(file) && line('.') > 2
|
if empty(file) && line('.') > 2
|
||||||
let file = s:sub(getline('.'), '/$', '')
|
let file = s:sub(getline('.'), '/$', '')
|
||||||
@@ -2908,8 +2908,9 @@ function! s:Browse(bang,line1,count,...) abort
|
|||||||
let rev = ''
|
let rev = ''
|
||||||
endif
|
endif
|
||||||
if rev ==# ''
|
if rev ==# ''
|
||||||
let expanded = s:buffer().rev()
|
let expanded = s:DirRev(@%)[1]
|
||||||
elseif rev ==# ':'
|
endif
|
||||||
|
if rev =~# '^:\=$'
|
||||||
let expanded = s:Relative('/')
|
let expanded = s:Relative('/')
|
||||||
else
|
else
|
||||||
let expanded = s:Expand(rev)
|
let expanded = s:Expand(rev)
|
||||||
@@ -3095,7 +3096,7 @@ function! s:ContainingCommit() abort
|
|||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! s:NavigateUp(count) abort
|
function! s:NavigateUp(count) abort
|
||||||
let rev = s:buffer().rev()
|
let rev = substitute(s:DirRev(@%)[1], '^$', ':', 'g')
|
||||||
let c = a:count
|
let c = a:count
|
||||||
while c
|
while c
|
||||||
if rev =~# ':.*/.'
|
if rev =~# ':.*/.'
|
||||||
@@ -3235,7 +3236,7 @@ function! s:cfile() abort
|
|||||||
let type = matchstr(getline(line('.')+1),'type \zs.*')
|
let type = matchstr(getline(line('.')+1),'type \zs.*')
|
||||||
|
|
||||||
elseif getline('.') =~# '^\l\{3,8\} '.myhash.'$'
|
elseif getline('.') =~# '^\l\{3,8\} '.myhash.'$'
|
||||||
let ref = s:buffer().rev()
|
let ref = s:DirRev(@%)[1]
|
||||||
|
|
||||||
elseif getline('.') =~# '^\l\{3,8\} \x\{40\}\>'
|
elseif getline('.') =~# '^\l\{3,8\} \x\{40\}\>'
|
||||||
let ref = matchstr(getline('.'),'\x\{40\}')
|
let ref = matchstr(getline('.'),'\x\{40\}')
|
||||||
|
|||||||
Reference in New Issue
Block a user