Live data from Hacker News

Neovim v0.5

github.com

191–200 of 213 posts

Re: Neovim v0.5

#191
post #7

The best developers and engineers I’ve known all used Neovim. Coincidence?

Don't worry there's lots of us mediocre humans using it too.

Seriously though this is cargo culting and is a bit silly.

I've used vim/neovim since the late 90s and think I know it pretty well. I don't fool myself that it has any bearing on developer ability.

Any job where where I've had the power to set tooling standards I've strongly pushed for build processes that allow developer freedom to choose any editor/IDE they want.

Most editor/IDE advocacy I've seen, like saddle choice on a bike, comes down to personal ergonomics.

Re: Neovim v0.5

#192

I'm using neovim with Coc (often does not work as I want it to) and ALE and friends, and it's getting sort of frustrating. It's lots of fiddling with the vimrc, each year a new better extension that I can never make work, etc. What I'd like is some editor that integrates LSP, treesitter, FZF and friends so I don't have to configure everything, while still having the modal+command model of vim. Recently there was an e…

LunarVim: A Neovim config made with sane defaults https://github.com/ChristianChiarulli/LunarVim LunarVim will be like Spacemacs/Doom Emacs/SpaceVim, but for neovim. A distribution of useful neovim packages with sane defaults. This project is still at its early stage and many things change rapidly. You currently cannot easily keep your custom changes in sync with LunarVim, but support for this feature is on the way.…

Indeed, it seems to tick quite a lot of boxes. I'm a bit confused on how to make it work with my old vimrc and plugins, and it doesn't seem to support julia's lsp yet, but I'll wait a few months, and hopefully this will be the solution I was looking for. Thanks!

Re: Neovim v0.5

#193
post #145

Earlier quoted context omitted.

I want to like LunarVim but the everything-lua is a bit overboard. Compare this ` vim.api.nvim_set_keymap('n', ' ', ':bprevious ', {noremap = true, silent = true})` to `nnoremap :bprevious ` Why convert every single line of vimscript to a noisier lua statement? The Packer manager seems a step back from vim-plug. Your configuration file is no longer the source of truth. Packer uses a global site directory for plugin a…

I have just started to play with neovim and the first thing I did was to define a function: function bindKey(mode, keys, command, options) options = options or {noremap = true, silent = true} return vim.api.nvim_set_keymap(mode, keys, command, options) end With that, remapping looks like this: bindKey('n', ' ', ':bnext ') Which is in my opinion better than Vim syntax. I definitely see the potential in having Lua as s…

Don't get me wrong I prefer lua to vimscript in almost every way. For migrating my existing settings, I didn't see the need to translate to lua, `vim.api.nvim_exec([[ ... ]])` and `vim.cmd('source ' .. path_to_vim_file)` work wonderfully. It's a joy to use lua for refactoring the remaining logic.

Re: Neovim v0.5

#194
post #145

Earlier quoted context omitted.

I'm interested in what modifications you have made. I've been trying LunarVim a bit for the last week and am on the fence about going back to SpaceVim or just bare neovim. Not sure, still evaluating...

I want to like LunarVim but the everything-lua is a bit overboard. Compare this ` vim.api.nvim_set_keymap('n', ' ', ':bprevious ', {noremap = true, silent = true})` to `nnoremap :bprevious ` Why convert every single line of vimscript to a noisier lua statement? The Packer manager seems a step back from vim-plug. Your configuration file is no longer the source of truth. Packer uses a global site directory for plugin a…

I agree about the 'everything in lua' config. I've found it frustrating.

Re: Neovim v0.5

#195
post #187

Earlier quoted context omitted.

lots of stuff. but mainly: * ease of getting started. nvim is just vim, you can bring over your vim config and it'll just work. * integrated lsp. you could have vscode like auto completion natively * tree-sitter. google it to believe it and much, much more

> you can bring over your vim config and it'll just work. Except when it doesn't: $ nvim init.vim Error detected while processing /home/martin/.config/nvim/init.vim: line 44: E474: Invalid argument: completeopt=menuone,popuphidden,noselect line 50: E518: Unknown option: completepopup=highlight:Pmenu,border:off E824: Incompatible undo file: /home/martin/.cache/vim/undo/%home%martin%.config%nvim%init.vim Or when openin…

I stand corrected. Is your experience based on nvim v0.5?

Re: Neovim v0.5

#196
post #187

Earlier quoted context omitted.

> you can bring over your vim config and it'll just work. Except when it doesn't: $ nvim init.vim Error detected while processing /home/martin/.config/nvim/init.vim: line 44: E474: Invalid argument: completeopt=menuone,popuphidden,noselect line 50: E518: Unknown option: completepopup=highlight:Pmenu,border:off E824: Incompatible undo file: /home/martin/.cache/vim/undo/%home%martin%.config%nvim%init.vim Or when openin…

I stand corrected. Is your experience based on nvim v0.5?

Yeah, that's Neovim 0.5. But it's been like this for years: when I tried Neovim 0.2 (or something? I don't recall the exact version, years ago anyway) I also got many errors and incompatibilities.

At this point, I think it's probably better to see Neovim as its own editor rather than "an improved Vim". Obviously based on Vim and still with close ties (many Vim patches are still backported), but the "it's just like Vim but with async + true colours"-days are long gone, and the differences will only increase in the future.

Personally, I even stopped making my plugins compatible with Neovim. For example methods ('foo bar'->split(' ')) aren't supported, but were added to Vim close to two years ago (Aug 2019). It's not that the Neovim people are against it: just no one bothered to port it as they prefer to work on the Lua stuff. I find it very convenient so I use it, and Neovim users... well... Sorry :-(

Re: Neovim v0.5

#197
post #40

Earlier quoted context omitted.

I know it sounds snarky, but at some point of vimrc complexity it’s worth considering just switching to vscode with the vim extension. It can use neovim as a back end and you get mountains of features out of the box. I created vim-idiomatic key mappings to all the vscode features and extensions I commonly use. It’s not vim, it uses a shit ton of memory, and you can’t run it in the terminal, but I love it. For context…

Another nice aspect of Neovim 0.5 is that you can do the entire configuration in Lua, so you can break out your config into multiple files and have things more organized and compartmentalized.

You can also break up your config with Vim script

Re: Neovim v0.5

#198
post #102

Earlier quoted context omitted.

> Putting the onus on plugin writers to rewrite essentially the same functionality is not ideal. This goes back to my biggest complaint with the vim ecosystem (and emacs has the same problem): no dependency management. Almost every plugin has to be self contained, because if you depend on another plugin, then you need to rely on you users to manually install that plugin.

Packer is a plug-in manager for neovim that uses packadd and has support for adding dependencies in the install step.

That's not quite the same as the package being able to declare its dependencies itself.

Re: Neovim v0.5

#199
post #28

NeoVim is very tempting to me. I've been tweaking my Emacs config for 5 years, and I'm very happy with it, but only on my Ubuntu computers. On Windows, Emacs runs like garbage (slow, no double-buffering). I might have to switch to NeoVim, at least on Windows.

The Emacs experience on Windows could be faster, but having switched from Neovim to Emacs on macOS I do not want to go back to Neovim now (and I was running the Neovim 0.5/dev branch with LSP and treesitter integration for some time). Your time might be better spent on improving Emacs performance on Windows if you can. I haven’t used Emacs on Windows for a little while, but I wonder if running it via WSL2 with the ne…

But neovim is only getting started. In a few years, the benefits of elisp over lua will probably be nil, and luajit is faster. I expect a lot of these points you make (which are valid) to become less and less relevant. First examples are already there : treesitter is as clean as can be, and telescope looks extremely nice. I'm waiting to see what people come up with for git, now that they don't have to learn vimscript or use slow python plugins.

Re: Neovim v0.5

#200
post #10

For those out there trying to "learn" vim, give neovim 0.5 a try! I've been using neovim HEAD (0.5 pre-release) for a while and it has been awesome. It all started with this config [0] and from there and haven't tried (as before) to join a vim cult but instead to use it as a tool that works for me (i.e. use mouse scroll to browse around, use arrows on insert mode, and other vim sins) Little by little I've been lookin…

Wow, I’ve been a vim user for like 8+ years and didn’t know about 0p even though I run into that problem all the time. I had even re-bound yank/paste to use a different register. Thanks for the pointer! This is what I love about vim, there’s always something new to learn.

To be perfectly honest I'm regularly surprised by techniques I don't know using plain old vi let alone Vim/NeoVim. That's still useful for situations where you only have say busybox vi.

I'm sure it's very well known but the "greatest stack overflow answer of all time" is an example[1] (IMHO obviously :D )

Vim Golf (also well known) is another invaluable and surprising resource[2].

1. https://stackoverflow.com/questions/1218390/what-is-your-mos...

2. http://www.vimgolf.com/

Post reply on HN