|
I use vim a lot and now I'm starting to love using tabs
(:tabnew, :tabfirst...),but I found that execution of the external command in one tab blocks the whole vim process. For example when I execute :make in one tab, I need to wait until this make finish. Will be very nice if someone provide me a solution how I can use other tabs in vim when I'm waiting something to finish in another opened tab. I still need the :copen output of :make command to be displayed in execution tab. I have same problem with :grep or :Ack(from :Ack module)... Regards, t0d0r -- You received this message from the "vim_use" maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php |
|
Hi,
2012/5/23 t0d0r <[hidden email]>: > I use vim a lot and now I'm starting to love using tabs > (:tabnew, :tabfirst...),but I found that execution of the external > command in one tab blocks the whole vim process. > > For example when I execute :make in one tab, I need to wait until this > make finish. Will be very nice if someone provide me a solution how I > can use other tabs in vim when I'm waiting something to finish in > another opened tab. I still need the :copen output of :make command to > be displayed in execution tab. I have same problem with :grep > or :Ack(from :Ack module)... https://github.com/Shougo/vimproc http://www.vim.org/scripts/script.php?script_id=3431 > > Regards, > t0d0r > > -- > You received this message from the "vim_use" maillist. > Do not top-post! Type your reply below the text you are replying to. > For more information, visit http://www.vim.org/maillist.php -- Ümit -- You received this message from the "vim_use" maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php |
|
In reply to this post by t0d0r
github.com/MarcWeber/vim-addon-async (see README)
-- You received this message from the "vim_use" maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php |
|
In reply to this post by t0d0r
2012/5/23 t0d0r <[hidden email]> -- I use vim a lot and now I'm starting to love using tabs This is my personal trick (from my ~/.vimrc): " F12 -> Attached Screen session: {{{ " ============================== " Build mapping: {{{ " cd $(dirname %:p) --> Change to current file's directory. " screen " -U -> Run in UTF-8 mode. " -d -> Deatach if previously attached. " -dRR vim_$(basename %:p) " -> Use current buffer file name as sessionname; then reattach it and, if necessary, detach or create it first. Use the first session if more than one session with same name are available. " -p %:p -> Use current buffer file full path as preselected (if available) window. " * TODO: Create this window by default when not exists. " -c ~/.vim/screenrc " -> Use modified screenrc config file (see below). "noremap <f12> :silent<space>!bash<space>-c<space>'cd<space>$(dirname<space>%:p);screen<space>-UdRR<space>vim_${PPID}<space>-e^qa<space>-p<space>"%"<space>-c<space>~/.vim/screenrc'<enter>:redraw!<enter> """""noremap <f12> :silent<space>!bash<space>-c<space>'cd<space>$(dirname<space>%:p);screen<space>-UdRR<space>vim_${PPID}<space>-p<space>"%"<space>-c<space>~/.vim/screenrc'<enter>:redraw!<enter> noremap <f12> :silent<space>!screen<space>-UdRR<space>vim_${PPID}<space>-c<space>~/.vim/screenrc<enter>:redraw!<enter> imap <f12> <esc><f12>a " }}} " Make screen session to be killed on exit and also prompting if dialog is installed: {{{ " ---------------------------------------------------------------------------------- autocmd VimLeave * !screen -ls vim_${PPID} | grep vim_${PPID} && dialog --yesno "Leave existing screen sessions alive?" 6 40 && screen -r vim_${PPID} || kill $(screen -ls vim_${PPID} | perl -ne 's/^.*?(\d{2,}).*$/\1/&&print') && clear " }}} " Prepare vim's screen configuration: {{{ " ---------------------------------- " Create ~/.vim directory if not already exists. silent !mkdir -p ~/.vim " Create/overwrite with user's ~/.screenrc if exists. silent !cat ~/.screenrc > ~/.vim/screenrc 2>/dev/null " Bind F12 to 'detach' command in screen. silent !echo 'bindkey -k F2 detach' >> ~/.vim/screenrc " Change default screen's escape key to CTRL-Q to avoid conflict if vim itself is running in other screen session. ""silent !echo 'escape ^qa' >> ~/.vim/screenrc " }}} " }}} -8<---------------------------------------- ...it needs GNU screen installed (apt-get install screen in debian/ubuntu) and "magically" create / recover a screen session propperly labeled and related to the same vim instance from which it was called (it would be easier to understand simply sourcing the code and pressing <F2> key twice (or more times). Regards. Joan Miquel Torres__________________________________ Linux Registered User #164872 http://www.mallorcaweb.net/joanmiquel BULMA: http://bulma.net http://breu.bulma.net/?l2301 -- You received this message from the "vim_use" maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php |
|
In reply to this post by t0d0r
On Wednesday, May 23, 2012 9:07:25 AM UTC-5, t0d0r wrote:
> I use vim a lot and now I'm starting to love using tabs > (:tabnew, :tabfirst...),but I found that execution of the external > command in one tab blocks the whole vim process. > > For example when I execute :make in one tab, I need to wait until this > make finish. Will be very nice if someone provide me a solution how I > can use other tabs in vim when I'm waiting something to finish in > another opened tab. I still need the :copen output of :make command to > be displayed in execution tab. I have same problem with :grep > or :Ack(from :Ack module)... > http://vim.wikia.com/wiki/Execute_external_programs_asynchronously_under_Windows -- You received this message from the "vim_use" maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php |
| Powered by Nabble | Edit this page |
