fix(vim-interaction): look up the newest GVim instance (#9095)

Instead of relying on a hardcoded instance-name existing for the default-value, let's
look up the latest instance. This also resolves my problem where MacVim
had a servername of "VIM" instead of "GVIM".

Co-authored-by: Johann Fridriksson <jofridri@silabs.com>
This commit is contained in:
Jóhann Friðriksson 2021-09-09 19:31:01 +02:00 committed by GitHub
parent 130f35fcb2
commit aa6e932b06
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -22,7 +22,8 @@ EOH
local cmd=""
local before="<esc>"
local after=""
local name="GVIM"
# Look up the newest instance
local name="$(gvim --serverlist | tail -n 1)"
while getopts ":b:a:n:" option
do
case $option in