Skip to content

Commit

Permalink
Merge pull request #238 from mrichards42/set-bufhidden
Browse files Browse the repository at this point in the history
keep_term_open also keeps hidden terminals open
  • Loading branch information
kassio authored Jun 21, 2019
2 parents d177900 + c48e0f8 commit 86eaa75
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,9 @@ Open a pull request to add REPLs and other features to this plugin. :smiley:

## Changelog

* 07/06/2019
- `g:neoterm_keep_term_open` keeps hidden terminals open even if they are
closed without using `:Tclose`
* 11/03/2019
- Make the `signcolumn=auto` in neoterm buffer.
* 29/01/2019
Expand Down
4 changes: 4 additions & 0 deletions autoload/neoterm.vim
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,10 @@ function! s:after_open(instance)
setlocal winfixheight winfixwidth
end

if g:neoterm_keep_term_open
setlocal bufhidden=hide
end

if g:neoterm_autoinsert
startinsert
elseif !g:neoterm_autojump
Expand Down
5 changes: 3 additions & 2 deletions doc/neoterm.txt
Original file line number Diff line number Diff line change
Expand Up @@ -171,8 +171,9 @@ Default value: `0`.

*g:neoterm_keep_term_open*

When set, neoterm terminal will be kept running in background. When not set,
`:bdelete!` is used to close neoterm in |:Tclose|.
When set, neoterm terminal will be kept running in background when the buffer
is hidden, or when closing via |:Tclose|. When not set, `:bdelete!` is used to
close neoterm in |:Tclose|.
Default value: `1`.

*g:neoterm_autoinsert*
Expand Down

0 comments on commit 86eaa75

Please sign in to comment.