vim: errors launching "/usr/bin/vi

Beau James b_james@pacbell.net
Wed Dec 20 02:47:17 GMT 2023


This problem appeared with my most recent Cygwin update that included an 
update to "vim".

My Cygwin installation now show vim version 9.0.2115.

Launching VIM from the shell running in a mintty window using the full 
pathname "/usr/bin/vim" works fine.

But launching "/usr/bin/vi" (which has worked fine for many years, until 
the most recent update), results in a long string of startup E319 errors:

>     $ /usr/bin/vi
>     Error detected while processing /usr/share/vim/vim90/filetype.vim:
>     line   11:
>     E319: Sorry, the command is not available in this version: let
>     did_load_filetypes = 1
>     line   14:
>     E319: Sorry, the command is not available in this version: let
>     s:cpo_save = &cpo
>     line   48:
>     E319: Sorry, the command is not available in this version: func
>     s:StarSetf(ft)
>     line   52:
>     E319: Sorry, the command is not available in this version: endfunc
    etc. etc.

Note that the startup errors appear only when using the full pathname 
"/usr/bin/vi". Using the command name alone ("vi") relying on the search 
path does not trigger the startup errors; using either the full pathname 
"/usr/bin/vim" or the command name alone "vim" relying on the search 
path does not trigger the startup errors.

I encountered this because some of my longtime 'convenience' Windows 
desktop links were launching a mintty window using "vi":

>     Target: C:\cygwin64\bin\mintty.exe -i /Cygwin-Terminal.ico
>     /usr/bin/vi /<targetfile>/

Easily fixed for me by changing "vi" to "vim". But don't know whether 
this change in behavior has any other implications?

Beau





More information about the Cygwin mailing list