Tex: [vista.vim] ctags: Warning: Unsupported kind: 'f' for --tex-kinds option
sanjayankur31 opened this issue · comments
Describe the bug
When attempting to use Vista
in a Tex file, I get these errors:
[vista.vim] ctags: Warning: Unsupported kind: 'f' for --tex-kinds option
[vista.vim] ctags: Warning: Unsupported kind: 'g' for --tex-kinds option
Environment:
-
OS: Linux
-
Vim/Neovim version: VIM - Vi IMproved 9.0 (2022 Jun 28, compiled Aug 14 2023 00:00:00) Included patches: 1-1712
-
This plugin version: f925e48
-
I'm using universal-ctags: yes
- Ctags version:
ctags --version
Universal Ctags 6.0.0, Copyright (C) 2015-2022 Universal Ctags Team
Universal Ctags is derived from Exuberant Ctags.
Exuberant Ctags 5.8, Copyright (C) 1996-2009 Darren Hiebert
Compiled: Feb 1 2023, 00:00:00
URL: https://ctags.io/
Output version: 0.0
Optional compiled features: +wildcards, +regex, +iconv, +option-directory, +xpath, +json, +interactive, +sandbox, +yaml, +packcc, +optscript
- Ctags version:
-
I'm using some LSP client:
- Related Vim LSP client: ALE
- The Vim LSP client version: 115ad17ace047cab20ccc67f79c943aaf3f0f291
- Have you tried updated to the latest version of this LSP client: Yes (ran
PlugUpdate
to ensure all plugins were updated)
Vista info
Current FileType: tex
Avaliable Executives: ['ctags']
Global Variables:
let g:vista = {'winnr': function('728'), 'tree': {}, 'source': {'fname': '00_general/diary/2023/2023-08-21.tex', 'bufnr': 1, 'get_winid': function('732'), 'winid': 1000,
'winnr': 1, 'extension': function('737'), 'line': function('735'), 'get_winnr': function('731'), 'filetype': function('733'), 'lines': function('734'), 'line_trimmed': func
tion('736'), 'scope_seperator': function('738'), 'fpath': '/home/asinha/Documents/05_Academics/2023_research_diary/00_general/diary/2023/2023-08-21.tex'}, 'without_scope': [
], 'get_tagline_under_cursor': function('730'), 'provider': 'ctags', 'skip_once_flag': v:false, 'with_scope': [], 'functions': [], 'raw': [], 'kinds': [], 'ctags_cmd': 'ctag
s --format=2 --excmd=pattern --fields=+nksSaf --extras=+F --sort=no --append=no --extras= --language-force=tex --tex-kinds=psbcufGPigl --output-format=json --fields=-PF -f-
/home/asinha/.cache/vista/5a656a8dfb41c3f1075489497d47efc31ffeb09adcf0362117fa27a519243170.tex', 'raw_by_kind': {}, 'tmps': [], 'winid': function('729')}
let g:vista#executive#ctags#support_json_format = 1
let g:vista#executives = ['ale', 'coc', 'ctags', 'lcn', 'nvim_lsp', 'vim_lsc', 'vim_lsp']
let g:vista#extensions = ['markdown', 'rst']
let g:vista#finders = ['clap', 'fzf', 'skim']
let g:vista_blink = [2, 100]
let g:vista_close_on_fzf_select = 0
let g:vista_close_on_jump = 0
let g:vista_cursor_delay = 400
let g:vista_default_executive = 'ctags'
let g:vista_disable_statusline = 1
let g:vista_echo_cursor = 1
let g:vista_enable_centering_jump = 1
let g:vista_executive_for = {}
let g:vista_find_absolute_nearest_method_or_function = 0
let g:vista_find_nearest_method_or_function_delay = 300
let g:vista_floating_border = 'none'
let g:vista_fold_toggle_icons = ['▼', '▶']
let g:vista_fzf_preview = []
let g:vista_icon_indent = ['└ ', '│ ']
let g:vista_ignore_kinds = []
let g:vista_no_mappings = 0
let g:vista_sidebar_position = 'vertical botright'
let g:vista_sidebar_width = 30
let g:vista_stay_on_open = 1
let g:vista_top_level_blink = [2, 100]
let g:vista_update_on_text_changed = 0
let g:vista_update_on_text_changed_delay = 500
Steps to reproduce given the above info
source file for reproduce the ctags issue:
Any Tex/LaTeX file: can also reproduce on this:
\documentclass[12pt]{letter}
\address{Somewhere}
\begin{document}
\begin{letter}{Some address}
\opening{Dear Sir or Madam,}
Some text
\closing{Yours sincerely,\\
\fromname{John doe}
}
\end{letter}
\end{document}
minimal vimrc (neccessary when this issue is about some Vim LSP client):
N/A (not related to LSP client, I don't think)
- Open a Tex/LaTeX file
- Run
Vista
Expected behavior
Vista viewer should come up
Actual behavior
No Vista viewer, warnings come up.
Screenshot or gif (if possible)
Possible fix:
I don't know too much about ctags. I saw that there were these two lines in autoload/vista/types/uctags/tex.vim
and removing them seems to "fix" the issue:
$ git diff
diff --git a/autoload/vista/types/uctags/tex.vim b/autoload/vista/types/uctags/tex.vim
index 22a1816..cf631dc 100644
--- a/autoload/vista/types/uctags/tex.vim
+++ b/autoload/vista/types/uctags/tex.vim
@@ -14,8 +14,6 @@ let s:types.kinds = {
\ 'P': {'long' : 'paragraphs', 'fold' : 0, 'stl' : 0},
\ 'G': {'long' : 'subparagraphs', 'fold' : 0, 'stl' : 0},
\ 'l': {'long' : 'labels', 'fold' : 0, 'stl' : 0},
- \ 'f': {'long' : 'frame', 'fold' : 0, 'stl' : 0},
- \ 'g': {'long' : 'subframe', 'fold' : 0, 'stl' : 0}
\ }
let s:types.sro = '""'
These two options are not available in the recent ctags, I have included your patch in #466, hopefully, it won't bring other side effects as I'm really not a tex user.