Topen just changes current filetype to neoterm and doesn't switch buffer in neovim
Closed this issue · 2 comments
OliverKnights commented
Apologies if I'm just using this wrong, but after using :Tnew to open a new terminal, changing to a normal buffer, say a .js file, then calling :Topen I expect the buffer the be changed back to the terminal if I'm understanding the documentation correctly, instead the filetype of the .js buffer is changed to neoterm and nothing else happens..
Steps to reproduce
- Open neovim (nvim -u ~/init.vim) with the following config
set nocompatible
filetype off
let &runtimepath.=',~/.config/share/nvim/plugged/neoterm'
filetype plugin on
- use :Topen or :Tnew to create a new terminal (this works correctly)
- switch to any other text file (:e ~/random-file.js)
- call :Topen, the filetype changes and the buffer remains the same
Thanks very much!
kassio commented
What do you mean by nothing else happens
? Can you add a gif, please?
OliverKnights commented
https://giphy.com/gifs/42CpuO3bzx5BmLrOb4
As the gif shows, the first call to :Topen works and opens a terminal, but if I open another file, and call :Topen again, I expect a new terminal to open? Instead the filetype changes to 'neoterm' and the buffer stays the same