Skip to content

Commit ff3f5cd

Browse files
authored
do not update alternate buffer on opening directory #196
Fixes #183 Test case: 1. Open Vim or Neovim 2. `:e file-a.txt` 3. `:e file-b.txt` 4. `:Dirvish` 5. Type `gq` 6. Type `<C-^>` 7. Confirm the current buffer was switched to file-a.txt
1 parent 5ba9ff3 commit ff3f5cd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

autoload/dirvish.vim

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -426,7 +426,7 @@ function! s:open_dir(d, reload) abort
426426
endfor
427427

428428
if -1 == bnr
429-
execute 'silent' s:noswapfile 'edit' fnameescape(d._dir)
429+
execute 'silent' s:noswapfile 'keepalt edit' fnameescape(d._dir)
430430
else
431431
execute 'silent' s:noswapfile 'buffer' bnr
432432
endif

0 commit comments

Comments
 (0)