vim-floaterm
vim-floaterm copied to clipboard
Startinsert only specific patterns
Before reporting
I want to do startinsert only for the following patterns. Because I'm using Floaterm to run tests, etc.
let g:floaterm_autoinsert = v:false
autocmd TermOpen,TermEnter term://*/zsh startinsert
But I can't do that because the following line will force the mode back to normal. https://github.com/voldikss/vim-floaterm/blob/b7747704c4df716efd21f331b4d94336c490a5ad/autoload/floaterm/util.vim#L60
I would like you to remove that line or add an option to skip it.
Describe your question, feature request, or bug.
Steps to reproduce
Using the minimal vimrc
set nocompatible
set hidden
set termguicolors
set runtimepath^=/path/to/vim-floaterm
filetype plugin indent on
syntax on
let g:floaterm_autoinsert = v:false
autocmd TermOpen,TermEnter term://*/zsh startinsert
" autocmd FloatermOpen term://*/zsh startinsert " -> overwritten
Steps to reproduce:
-
:FloatermNew
- Check the mode
Actual behaviour
Return to normal mode when opening zsh on floaterm
Expected behaviour
I want to do startinsert only when the execution is zsh.
I propose that this option should be removed completely. Startinsert can be controlled by the users with autocommands, there is no need for us to have this.
I propose that this option should be removed completely. Startinsert can be controlled by the users with autocommands, there is no need for us to have this.
RIGHT!!! I feel that the plugin has exposed so much interfaces/options which users can implement via easy vimscript. These redunant options increases the complexity of the plugin and I'm considering to remove them.