[vim/vim] bash function missing support for names with : characters (Issue #19895)

3 views
Skip to first unread message

KodeToad

unread,
Apr 2, 2026, 4:29:30 PM (10 hours ago) Apr 2
to vim/vim, Subscribed
KodeToad created an issue (vim/vim#19895)

Steps to reproduce

  1. create a function with the : character in the name. for example
#!/bin/bash
function ssh:exit_master_connection() {
 : # code ... 
}
ssh:exit_master_connection 'git@host'
  1. run ctags universal produces the following tag:
    ssh::exit_master_connection /root/bin/fn/ssh-functions /^function ssh::exit_master_connection() {$/;" f
  2. edit the file and place the cursor over the call to the function
  3. ^]
  4. Result is E426: Tag not found: create_master_connection

Expected behaviour

The function definition would be jumped to.
This function naming convention is recommended by the styleguide

Version of Vim

vim --version VIM - Vi IMproved 9.2 (2026 Feb 14, compiled Mar 21 2026 11:38:26) Included patches: 1-218 Modified by team...@tracker.debian.org Compiled by team...@tracker.debian.org Huge version without GUI. Features included (+) or not (-): +acl +jumplist +sodium +arabic +keymap -sound +autocmd +lambda +spell +autochdir +langmap +startuptime -autoservername +libcall +statusline -balloon_eval +linebreak -sun_workshop +balloon_eval_term +lispindent +syntax -browse +listcmds +tabpanel ++builtin_terms +localmap +tag_binary +byte_offset -lua -tag_old_static +channel +menu -tag_any_white +cindent +mksession -tcl +clientserver +modify_fname +termguicolors -clipboard +mouse +terminal +clipboard_provider -mouseshape +terminfo +cmdline_compl +mouse_dec +termresponse +cmdline_hist +mouse_gpm +textobjects +cmdline_info -mouse_jsbterm +textprop +comments +mouse_netterm +timers +conceal +mouse_sgr +title +cryptv -mouse_sysmouse -toolbar +cscope +mouse_urxvt +user_commands +cursorbind +mouse_xterm +vartabs +cursorshape +multi_byte +vertsplit +dialog_con +multi_lang +vim9script +diff -mzscheme +viminfo +digraphs +netbeans_intg +virtualedit -dnd +num64 +visual -ebcdic +packages +visualextra +emacs_tags +path_extra +vreplace +eval -perl -wayland +ex_extra +persistent_undo -wayland_clipboard +extra_search +popupwin -wayland_focus_steal -farsi +postscript +wildignore +file_in_path +printer +wildmenu +find_in_path +profile +windows +float -python +writebackup +folding -python3 -X11 -footer +quickfix +xattr +fork() +reltime -xfontset +gettext +rightleft -xim -hangul_input -ruby -xpm +iconv +scrollbind -xsmp +insert_expand +signs -xterm_clipboard +ipv6 +smartindent -xterm_save +job +socketserver system vimrc file: "/etc/vim/vimrc" user vimrc file: "$HOME/.vimrc" 2nd user vimrc file: "/.vim/vimrc" 3rd user vimrc file: "/.config/vim/vimrc" user exrc file: "$HOME/.exrc" defaults file: "$VIMRUNTIME/defaults.vim" fall-back for $VIM: "/usr/share/vim" Compilation: gcc -c -I. -Iproto -DHAVE_CONFIG_H -Wdate-time -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/vim-9.2.0218=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -fcf-protection -DSYS_VIMRC_FILE="/etc/vim/vimrc" -DSYS_GVIMRC_FILE="/etc/vim/gvimrc" -D_REENTRANT -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1 Linking: gcc -Wl,-z,relro -Wl,-z,now -Wl,--as-needed -o vim -lm -ltinfo -lselinux -lsodium -lacl -lattr -lgpm

Environment

OS: Debian Trixie
Terminal: putty 0.83
$TERM: xterm
shell: GNU bash, version 5.2.37(1)-release (x86_64-pc-linux-gnu)
ctags: Universal Ctags 6.2.1

Logs and stack traces


Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/issues/19895@github.com>

KodeToad

unread,
Apr 2, 2026, 4:58:14 PM (9 hours ago) Apr 2
to vim/vim, Subscribed
KodeToad left a comment (vim/vim#19895)

This is also a problem when using * to find the next occurrence and I bet all the other search routines involving strings.


Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/issues/19895/4180435767@github.com>

Aliaksei Budavei

unread,
Apr 2, 2026, 5:38:43 PM (8 hours ago) Apr 2
to vim/vim, Subscribed
zzzyxwvut left a comment (vim/vim#19895)

Try adding : to &iskeyword and balancing the number of :s
used in the shell script and the tags file (there are too
many :s in your posted tags file excerpt).

Another tags generator exuberant-ctags only generates ssh
for the leading field, e.g.:

ssh	/tmp/path/to/tests/test.sh	/^function ssh:exit_master_connection() {$/;"	f

and Vim does find such a definition with Ctrl-].


Reply to this email directly, view it on GitHub, or unsubscribe.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/issues/19895/4180631792@github.com>

Reply all
Reply to author
Forward
0 new messages