6 ms·
As someone who uses regular Vim as a (fairly modified) daily driver, can you explain what NeoVim brings to the table? My main gripe with Vim is that system clip
by tomcatfish 8y ago
As someone who uses regular Vim as a (fairly modified) daily driver, can you explain what NeoVim brings to the table? My main gripe with Vim is that system clipboard support on my copy doesn't work, and without custom compilation, the only version it really works in is GVim, which I find kind of distracting.
- shmerl 8y agoFor me neovim brought true color themes support in the terminal, which was a breath of fresh air, or rather a major relief for my eyes. I switched to it for that reason, and using it ever since.
- eeks 8y agoRe: your clipboard issues, which platform are you running on? I am using vim+iTerm2 on OSX and vim+st on OpenBSD and the clipboard integration works flawlessly.
- dsr_ 8y agoI suspect vim on Debian Stretch, which now ships with "please break selection mechanisms" as a default. The fix is set mouse="" and/or have a ~/.vimrc
- OscarDC 8y agoA working workaround for me was to alias vi to `gvim -v` instead. It launches gvim without the GUI (so... vim), but still keep clipboard support.
- scribu 8y agoThe main benefit of Neovim for me is support for async jobs. So, for example, if you have autosave enabled, it won’t block the UI while it’s writing to disk.
- DominoTree 8y agoAt this point, vanilla Vim has async jobs as well, although it's not as clean as NeoVim
- kerny 8y agocan you expand a bit more on "not as clean" as NeoVim? I consider vim's implementation of async jobs simpler than neovim's.
- OscarDC 8y agoVim now also supports async jobs since Vim 8 (but with a different API). IIRC, neovim implementation was first proposed as a vim PR before the fork happened. The mess following it was one of the main reason behind the fork.
- dhotson 8y agoClipboard seems to work well for me with this config: set clipboard+=unnamedplus More details on that here: https://neovim.io/doc/user/provider.html#provider-clipboard https://neovim.io/doc/user/provider.html#provider-clipboard A couple of small things I really like: :set inccommand=nosplit ... this gives you a live view of substitutions as you type out a replacement e.g :%s/foo/bar/ :term :vs term://bash ... these gives you a proper embedded terminal window inside vim. Also, I think vim8 has it as well, but something people might not realise is you can use truecolor gui color schemes (not limited to 256 color) in the terminal with :set termguicolors It also has a guicursor option for making the cursor display as a block or bar in the terminal depending on which mode you're in: https://neovim.io/doc/user/options.html#'guicursor' https://neovim.io/doc/user/options.html#'guicursor' Other than that, there's a more thorough list of differences here: https://neovim.io/doc/user/vim_diff.html https://neovim.io/doc/user/vim_diff.html
- syrrim 8y agoVim has termguicolors since a couple years now. Not sure about the other stuff, but Bram's been copying a lot of nvim's exclusive features it seems.
- juancampa 8y agoWhoa, I had no idea about inccommand. I just tried and it's amazing. Thanks!
- dhotson 8y agoWhen you test it out, make sure you try: :set inccommand=split It's pretty cool, but I just prefer the nosplit way since it's less obtrusive. :) It ends up being similar in use to how many modern editors have multiple cursors.
- kjeetgill 8y agoMy pet favorite: opening a terminal in a vim split. Having an interactive bash/ipython/repl session where you can use vim keys to navigate and yank lines from your scrollback is pure bliss. I like to run builds and be able to see, yank, open files from the errors all inside vim.
- tostr 8y agoHow does one get back to "terminal content as a buffer" from the interactive version of the terminal?
- kjeetgill 8y agofrom: https://neovim.io/doc/user/nvim_terminal_emulator.html https://neovim.io/doc/user/nvim_terminal_emulator.html "In [terminal] mode all keys except <C-\><C-N> are sent to the underlying program. Use <C-\><C-N> to return to normal-mode."
- JdeBP 8y agoThis and more is explained in the doco. :help terminal-emulator-input
- dmortin 8y agoWhy did it take VIM so long to get this? Emacs has this feature for 30 years or so.
- pasabagi 8y agoIt's a very emacsy idea. I think, for better or worse, vim is centered around the goal of making a better editor. Emacs is centered around making a portable universe. To be honest, I don't really like having a 'terminal' in vim. It makes more sense to just use the terminal, which is like, right there, one ctrl-z away.
- kjeetgill 8y agoI don't like Neovim's terminal mode because I need a terminal. I'm also a religious ctrl-z user. I use it when I want to be able to yy stuff out of the scrollback to use in the split with my code like parts of a live repl session or the output from curl.
- billturner 8y agoCan't answer about copy/paste an NeoVim, but I just switched from vim -> neovim this week, and do feel it's a bit snappier. I also switched from syntastic to ALE for syntax checking and that made a huge difference as well. For copy/paste in the terminal and vim, I usually have vim in a tmux session, and that has a few helpers to work with system clipboards. Not perfect, but better than vanilla vim's copy/paste.
- pasabagi 8y agoThe differences are very small. I use both, nvim for programming, and vim for everything else. This is for no real reason - it's just turned out that way. Some programming-related plugins I use work better on neovim, although there are also some where it's smoother sailing on vanilla. I rarely notice any difference whatsoever in terms of behaviour.
- dcosson 8y agoYou don't need to compile vim for clipboard support these days. On Mac, `brew install vim`, on Ubuntu `apt-get install vim-gtk`. The latter I think comes with the gui version of vim but you don't have to use it, it also includes a `vim` binary with clipboard support.
- geoelectric 8y agoOn Mac, for regular Vim I recommend `brew install macvim --with-override-system-vim` That gives you MacVim's native Cocoa GUI while also using its console version as the system-wide vim.
- wyclif 8y agoThat's a good idea, but only for those who need to have full XCode installed. If you only have XCode Command Line Tools installed, I think it's better to just use console vim + tmux.
- geoelectric 8y agoI wasn't aware you needed full XCode. That is a burden. You can also brew cask install macvim and symlink the console exe from within the .app bundle (which is essentially what the regular brew formula does as well).
- liveoneggs 8y agoit's slightly faster to start up, is a big one
- geoelectric 8y agoTaking a stab, but you're not using Vim under tmux on a Mac, are you? If so, you need to do a tweak to get clipboard access. https://robots.thoughtbot.com/how-to-copy-and-paste-with-tmux-on-mac-os-x https://robots.thoughtbot.com/how-to-copy-and-paste-with-tmu... Otherwise the "+y / "+p commands should yank and paste system clipboard correctly.