jalvesaq / vimcmdline

Send code to command line interpreter
GNU General Public License v2.0
223 stars 38 forks source link

Cannot start external terminal for python #87

Closed ImNotaGit closed 4 years ago

ImNotaGit commented 4 years ago

Hi, I'm using Vim 8.1 with tmux. I have been using Nvim-R for a long while and found it very useful. Now hoping to make it work for Python, I installed and set up vimcmdline as instructed, by adding this line to my .vimrc:

let cmdline_external_term_cmd = "xterm -e '%s' &"

Then I opened an example.py file and pressed s (in my case it's \s), but there's no reaction and an external terminal was not opened.

:echo cmdline_tmuxsname has some value of 'vcl' plus a string of numbers assigned to 'python'; :echo cmdline_job has everything with 0 value. I'm not sure how to further debug this.

Could you please help with this? Thanks in advance.

jalvesaq commented 4 years ago

Could you try Neovim? It can run python in its built-in terminal emulator.

jalvesaq commented 4 years ago

I have just tried Vim 8.1 (default Vim on ubuntu 19.10) with xterm (configured as in your initial report), and it works. Python starts normally. Note: it's python, and not iPython.

ImNotaGit commented 4 years ago

Thanks much for the quick reply. I realized that the issue is with X11 forwarding and set DISPLAY, not with vimcmdline:) I'll try Neovim though since I do prefer the format of and internal terminal within the same window.