antoinemadec / coc-fzf

fzf :heart: coc.nvim

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

An additional position appears in the jump list when using coc-reference

rainzm opened this issue · comments

Environment

  • echo $FZF_DEFAULT_OPTS:
(nothing)
  • bat --version:
bat 0.15.4
  • Are your vim plugins up-to-date?:
yes
  • (n)vim --version:
(n)vim --version output
NVIM v0.4.4
Build type: Release
LuaJIT 2.0.5

Describe the Bug

An additional position appears in the jump list when use coc-reference.
When i use coc-reference(gr), i select an item from the float window that pops up and jump to the reference position.
The beginning of the referenced file appears in the jump list and i can't go back via once CTRL-O.
This is the screeshot:

coc-fzf

When i disable coc-fzf, no additional position apperas. And the screenshot(also expected) is:

nococ-fzf

To Reproduce

Minimal vimrc

" minimal vimrc
set nocompatible
filetype plugin indent on
syntax on
set hidden

call plug#begin('~/.vim/plugged')
Plug 'neoclide/coc.nvim', {'do': 'yarn install --frozen-lockfile'}
Plug '~/.fzf'
Plug 'junegunn/fzf.vim'
Plug 'antoinemadec/coc-fzf'
call plug#end()

nmap <silent> gd <Plug>(coc-definition)
nmap <silent> gi <Plug>(coc-implementation)
nmap <silent> gr <Plug>(coc-references)

Steps to Reproduce

Premise

  1. More than one reference so that fzf list will pop.
  2. Jump from one file to anther file.

Expected Behavior

No additional position in jump list and i could jump back via once CTRL-O.

Thanks in advance.

@rainzm , thanks for reporting the bug!
I was able to reproduce this.

It should be fixed today or tomorrow 👍

@rainzm , the fix was easy 😃
Please confirm it fixed your issue.

@antoinemadec It works. Thanks for your quick fix.