Skip to content

g:vimtex_complete_bib does not affect the text formation in the popup menu and preview  #2712

@L-TChen

Description

@L-TChen

Description

Thanks for this powerful plugin. I have been enjoying this plugin for a long time.

I come across the issue that the global variable g:vimtex_complete_bib does not affect how the text is formatted by the citation completion. Then, I realise that the completion information is cached so the change does not affect the previously cached results. Surely it was mentioned in #2444 as well.

Is there any way to detect the change of text formatting rule and clean up the cache automatically? Or, at least, please document this behaviour about g:vimtex_complete_bib in :h vimtex? (I can send a PR for the latter approach , but I think it is rather suboptimal ...)

Steps to reproduce

\documentclass{article}

\begin{document}
\bibliographystyle{plain}
\bibliography{reference}
\end{document}

The text formatting rule applies if I disable the persistent cache.

call plug#begin()
Plug 'lervag/vimtex'
call plug#end()

" let g:vimtex_cache_persistent = 0
let g:vimtex_complete_bib = {
	\ 'menu_fmt': '@author_all (@year), "@title"',
	\}

Expected behavior

No response

Actual behavior

No response

Do you use a latexmkrc file?

no

VimtexInfo

System info:
  OS: macOS 12.6.5 (21G531)
  Vim version: VIM 9.0 (1-1276)
  Has clientserver: true
  Servername: VIM

VimTeX project: minimal
  base: minimal.tex
  root: /Users/liang-tingchen/Downloads
  tex: /Users/liang-tingchen/Downloads/minimal.tex
  main parser: current file verified
  document class: article
  compiler: latexmk
    engine: -pdf
    options:
      -verbose
      -file-line-error
      -synctex=1
      -interaction=nonstopmode
    callback: 1
    continuous: 1
    executable: latexmk
  viewer: General
  qf method: LaTeX logfile

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions