Skip to content

Commit

Permalink
bug fix for #32 ensuring return to previous buffer
Browse files Browse the repository at this point in the history
  • Loading branch information
williamjameshandley committed Jan 9, 2021
1 parent d734943 commit df066a5
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Vimteractive
============
:vimteractive: send commands from text files to interactive programs via vim
:Author: Will Handley
:Version: 2.4.0
:Version: 2.4.1
:Homepage: https://github.com/williamjameshandley/vimteractive
:Documentation: ``:help vimteractive``

Expand Down
3 changes: 2 additions & 1 deletion autoload/vimteractive.vim
Original file line number Diff line number Diff line change
Expand Up @@ -90,9 +90,10 @@ function! vimteractive#sendlines(lines)
" Switch to insert mode if the terminal is currently in normal mode
let l:term_status = term_getstatus(b:vimteractive_connected_term)
if stridx(l:term_status,"normal") != -1
let l:current_buffer = bufnr('%')
execute ":b " . b:vimteractive_connected_term
execute "silent! normal! i"
bprevious
execute ":b " . l:current_buffer
endif

if get(g:vimteractive_bracketed_paste, l:term_type, g:vimteractive_bracketed_paste_default)
Expand Down

0 comments on commit df066a5

Please sign in to comment.