Copy these or git clone https://github.com/sapri987/minimum-reproducible-vim-ctags
./importer.py
from . import importee
myvariable = importee.variable
./importee.py
def variable():
pass
./a_irrelevant_file.py
def variable():
return 'irrelevant'
Instead of copy pasting you can
git clone https://github.com/sapri987/minimum-reproducible-vim-ctags
Note : if you copy paste, name the files as i did because vim goes to the first file in alphabetical order.
ctags -R .
vim importer.py
set cursor on variable and C-] brings you to the irrelevant definition.
gC-] is not a good solution in my opinion because it is stated at line 1 which file is relevant.
vim know which file is relevant because of the import statement and the fact that variable is preceded by importee., and brings you directly to the relevant definition
9.2 1-623
Arch Linux
xterm
bash 5.3.15
—
Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!
You are receiving this because you are subscribed to this thread.![]()
:h tag-priority
ctags don't know what file is imported.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!
You are receiving this because you are subscribed to this thread.![]()
You can use pyright or 'ty'.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!
You are receiving this because you are subscribed to this thread.![]()
command! -nargs=1 -complete=tag TagLocal execute 'tag ' . filter(taglist(<q-args>), { _,v->fnamemodify(v.filename,":p" ) == expand("%:p")})->get(0,{})->get( 'name','')
If you want local tag completion look into -complete=customlist,YOURFUNC
—
Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!
You are receiving this because you are subscribed to this thread.![]()
set cscopetag shows a list when multiple tags are found.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!
You are receiving this because you are subscribed to this thread.![]()