Terminal window does not appear before pressing any button
Describe the bug I have the mapping:
nnoremap <silent> <leader>r :REPLToggle<cr>
When I do <leader>r, I have to press a button in order for the terminal to appear. For example, if I do:
<leader>r
<enter> a
Then in terminal/REPL I will have:
$
$ a
How can the REPL/Terminal appear directly when invoked with <leader>r?
Screenshots If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):
VIM-REPL, last update: 2019.8.23
Operation System: Darwin
Support python3: 1
Support python: 0
has +terminal: 1
has +timers: 1
3.7.9 (default, Aug 31 2020, 07:24:53)
[Clang 10.0.0 ]
REPL program:
{'default': ['bash'], 'python': ['ipython']}
REPL exit commands:
{'zsh': 'exit', 'bash': 'exit', 'default': 'exit', 'python': 'quit()', 'ipython': 'quit()'}
Current File Type: vim
Current Type: bash
Current Exit Commands: exit
Additional context I have set the following mappings:
let g:repl_position = 0
"
" Choose to have the cursor staying at REPL after opening it
let g:repl_stayatrepl_when_open = 1
"
" Choose programs to run when opening REPL
let g:repl_program = {
\ 'python': ['ipython'],
\ 'default': ['bash']
\ }
"
" Define iPython version
let g:repl_ipython_version = '7'
An update on this.
The above is happening only if I specify the mapping. The call of the :REPLToggle functions properly. That is, if I just use the :REPLToggle, then the terminal appears directly. If I use the mapping <leader>r, then the terminal appears if I press another key after the <leader>r.
Any ideas what is happening and the terminal/REPL is not appearing immediately when using the mapping?
It's very strange because the same setting works fine on my machine. What's the version of your vim?
Hi,
My Vim is 8.2.2