Skip to content

Commit 08b871b

Browse files
author
skywind3000
committed
Add support for getting the top directory in Magit buffers in asyncrun locator script.
1 parent 419d31e commit 08b871b

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

autoload/asyncrun/locator.vim

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,10 @@ function! asyncrun#locator#buffer_path()
2525
return t:git['git_root']
2626
endif
2727
endif
28+
elseif &ft == 'magit'
29+
if exists('b:magit_top_dir')
30+
return b:magit_top_dir
31+
endif
2832
endif
2933
if exists('b:git_dir')
3034
return b:git_dir

0 commit comments

Comments
 (0)