Hacker News new | ask | show | jobs
by magv 1996 days ago
For those of us that don't use Lisp (or Emacs+SLIME), and are stuck with Python/Julia/Lua/etc and Vim may I give a practical recommendation? The Vim-Slime plugin [1] is a half-decent way of making interactive development work. With a bit of tuning you can make it start a terminal emulator window inside Vim, and have it send the current paragraph of your source code into it with a press of a button.

While not as great as working with a proper Repl-oriented language (as the article explains), this is still so much more pleasant than having to re-run the whole program every time you change a function.

[1] https://github.com/jpalardy/vim-slime

5 comments

I also recommend jupyterlab for a similar experience. I was a hardcore vim terminal guy for 17 years, but now I won’t be going back.

The ability to interactively develop functions in almost any language inside the same environment had been revolutionary for my productivity given my short attention span.

If you're using Jupyter within the browser you can have both via the FireNVim plugin in Firefox. It connects to NeoVim in the background and lets you edit any multi-line text field with 100% of your personal Vim configuration, the only limitation is that the color scheme cannot be changed.
FYI I use firenvim daily and it can certainly change color scheme. Is it only when used with Jupyter that color scheme can't be changed?
Would you mind sharing what you're doing with JLab? Do you use it in machine learning or are you doing something completely different?
Some amount of data science, some amount of node development of various kinds. Only about 10% ML work.
> With a bit of tuning you can make it start a terminal emulator window inside Vim, and have it send the current paragraph of your source code into it with a press of a button.

Defining keybindings for splitting the window, opening a terminal buffer and copying a paragraph does not really require a plugin. That's one of the features I like most in Vim, its ability to just map any input to another sequence of keypresses can replace whole scripts and plugins provided you're fine with readability comparable to regular expressions.

And nvim-R for vim/nvim and R.

[1] https://github.com/jalvesaq/Nvim-R

Without caring about VIM, this would be my options,

Python IDE tooling on Microsoft stack.

https://docs.microsoft.com/en-us/visualstudio/python/python-...

Juno IDE for Julia

https://junolab.org/

Another way is ipython %edit magic command and $EDITOR set to vim and using %autoreload

https://ipython.org/ipython-doc/3/config/extensions/autorelo...