aboutsummaryrefslogtreecommitdiff
path: root/vimrc-full
diff options
context:
space:
mode:
authorMax Christian Pohle2017-11-03 01:46:13 +0100
committerMax Christian Pohle2017-11-03 01:46:13 +0100
commit694a8236d1418c51cafeefcbbdaa0c76844a6a0a (patch)
treea25d3e352b45dd86abf8b0cf391d0763b992c3a3 /vimrc-full
parentc838cbbf34b66fcc5ec47e8a7262e7458d41cd85 (diff)
downloadvim-694a8236d1418c51cafeefcbbdaa0c76844a6a0a.tar.bz2
vim-694a8236d1418c51cafeefcbbdaa0c76844a6a0a.zip
Send files from one session to another using the menu
Diffstat (limited to 'vimrc-full')
-rw-r--r--vimrc-full11
1 files changed, 9 insertions, 2 deletions
diff --git a/vimrc-full b/vimrc-full
index 383951b..92324c3 100644
--- a/vimrc-full
+++ b/vimrc-full
@@ -286,8 +286,15 @@ else " default Vim?
286 autocmd BufWinLeave * call clearmatches() 286 autocmd BufWinLeave * call clearmatches()
287 endif 287 endif
288 288
289 menu &UI.&Open\ in\ Serversession 289 function! Refresh_server_list()
290 \ :execute ":bd<Bar>:call remote_send('GVIM', ':e ' . expand('#:p') . '\<CR\>')"<CR> 290 silent! unmenu! UI
291 menu &UI.refresh\ server\ list :call Refresh_server_list()<CR>
292 menu &UI.-Sep1- :
293 for s in split(serverlist(), '\n')
294 execute ':menu &UI.&Open\ in\ '.s." :execute \":bd<Bar>:call remote_send('".s."', ':e ' . expand('#:p') . '\\<CR\\>')<Bar>:call remote_foreground('".s."')\"<CR>"
295 endfor
296 endfunction
297 autocmd! VimEnter * call Refresh_server_list()
291 298
292 " scripts from the default vim installation, which do not get loaded by default, but are useful. 299 " scripts from the default vim installation, which do not get loaded by default, but are useful.
293 if filereadable($VIMRUNTIME.'/macros/editexisting.vim') 300 if filereadable($VIMRUNTIME.'/macros/editexisting.vim')
..