Neovim: Rebuilding Vim For the 21st Century 248
An anonymous reader writes "Neovim is a major overhaul of the vim editor to provide better scripting, cleaner support for plugins and integration with modern graphical interfaces. Modernising the large and complex codebase of Vim is a formidable task, but the developer has a clear plan, and has already begun work. There's a Bountysource fundraiser running to support the effort. If Vim is your editor of choice, check it out." (The crowd-funding effort has only one more day to go, but has well exceeded already the initial goal of $10,000.)
Obligatory xkcd, and rirst post (Score:5, Funny)
http://xkcd.com/378/
Re: (Score:2)
Hey, it's not that bad, it's strapline does include "sarcasm", after all. This is an ancient debate and deserves a smile or two on this auspicious occasion - modernising vi / vim is a laudable goal.
Think about the comfort and ease of use, if one could use Alt-Gr for the shortcuts in Vim, and ALT-TAB etc. to switch instantly for other GUI apps (SSH, Seamonkey, etc.). A long-awaited blend of the old and the new.
Re: (Score:2)
Re: (Score:2)
Insert mode? Command mode? Etc. etc.
I can do without.
Now, arguably, if all you have to work with is command line, that's one way to make it work, and work well. But most of the time I'd rather make use of modern interfaces.
Re: (Score:2)
Re: (Score:2)
Re: (Score:3)
Re: (Score:3)
Vim has a boatload of special states. And they are anything but obvious or visible. That's bad in the first weeks, then suddenly it becomes very good.
FTFY
Re: (Score:2)
Perhaps this one is more appropriate:
http://xkcd.com/1343/ [xkcd.com]
Re: (Score:2)
Hardcore guys ride V-twins and run Emacs on their android https://play.google.com/store/... [google.com] .
Trivially accomplished (Score:5, Funny)
Re:Trivially accomplished (Score:5, Funny)
for those who wonder how Stallman could flounder around for 35+ years and not produce a viable OS, look no further than his "editor"
Re: (Score:2)
for those who wonder how Stallman could flounder around for 35+ years and not produce a viable OS, look no further than his "editor"
It's a fairly complete OS but needs a good editor.
Viper-mode (Score:3)
Re: (Score:2)
Right... because emacs is a dropin replacement for vim...
Might as well suggest MSWord, Libreoffice or LaTeX.
Re: (Score:2)
formidable task != $10k budget (Score:5, Interesting)
if someone came to me to evaluate their budget reasonableness for something they described as a formidable task taking more than a week or two, and asked for $10k, I'd know they were egregiously underestimating or something is missing.
(and as TFA says: "Over its more than 20 years of life, vim has accumulated about 300k lines of scary C89 code that very few people understand or have the guts to mess with."... that's pretty formidable)
I suppose some ambitious person living in a low cost of living locale could survive for 6 months on 10k, and that would be a fair amount of work time; toiling in their barren garret or tower.
TFA says "$10,000 will allow me to dedicate two months of full time work to this project, which will be enough to implement the following:"
Is $5000/mo a reasonable sum in Recife, Brazil? Probably.
Is 2 months sufficient time to do all he wants to do? I'm not so sure. That's a pretty long list of things he wants to do.
Re: formidable task != $10k budget (Score:3)
A consulting company would ask 1,000 to 2,000 per day, so 40,000 to 80,000.
Re: (Score:2, Interesting)
I'm a Brazilian, though I don't live in Recife.
> Is $5000/mo a reasonable sum in Recife, Brazil? Probably.
Agreed.
USD $5,000 is a hefty sum in Brazil to be earned for a month's work, though it's not obscene. Some things are way expensive here (like cars and houses), some are somewhat more expensive (like computers) and some are cheap (like food). We're more or less like an inverted Japan, in economic terms.
From his previous initiatives, the guy seems to belong to a category with few people who could deser
Re: (Score:2)
Re: (Score:2)
Depends, are you paying me in BitCoins so I don't pay taxes?
I live on just about $5.3K per month, which is what the government lets me keep of my 6 figure income, and I save out of that amount too.
Re: (Score:2)
(that is for a family of 4, btw, not just myself. Much lower burn rate if it was just me, but I like my family =) )
Certainly as a fork... good luck (Score:5, Interesting)
I admit to being curious to see how this one goes as a fork off the existing vim codebase, but I'm not sure I'd be putting any bets on its long term viability. I suspect an overdose of optimism and insufficient compelling reasons for users to shift from vim will starve this project out.
Good luck to the developer - it's going to be one hell of a learning experience.
Re: (Score:2)
Re: (Score:2)
Vim's Bram Moolenaar on 'Neovim' (Score:5, Informative)
https://groups.google.com/foru... [google.com]
"It's going to be an awful lot of work, with the result that not all systems will be supported, new bugs introduced and what's the gain for the end user exactly?
Total refactoring is not a solution. It's much better to improve what we have. Perhaps with some small refactorings specifically aimed at making Vim work better for users."
Re: (Score:2)
It sounds more like a task that the maintainers of VIM should actually be undertaking on the main branch. One step at a time.
Re:Vim's Bram Moolenaar on 'Neovim' (Score:5, Informative)
The origin of the fork is that tarunna submitted two large patches to vim that would have fixed a lot of process management in vim, and was rejected because the current vim codebase is so large and crufty that it's impossible to make major architectural changes to it, like allowing for async process management, just because the risk is too high (especially when there's literally one person, Moolenaar, with a commit bit and thus accepting responsility for every change). And the risk really is very high, I'm not faulting Moolenaar for this.
The gain is that (neo)vim will be able to keep up with current technologies in its plugins (like non-blocking operations), it'll allow plugin authors to write faster plugins by speeding up the plugin architecture, existing plugins will see a speed increase, and other programs will be able to embed vim as an editor rather than hacky "vim keybindings" plugins. Given time and asm.js, it'll run natively within a web browser. None of these were in reach with Moolenaar squatting on the code rejecting risky patches. Sounds like a lot of gains to me.
Re: (Score:2)
As a data point, a while back I peaked into the Vim source code and was amazed at how complicated the code base was. On the other hand I was very impressed with the sophisticated data structures it was using to support large files efficiently.
Re:Vim's Bram Moolenaar on 'Neovim' (Score:5, Insightful)
The root problem here that tarruda is addressing (and he's very explicit about this in the neovim newsgroup) is that the code needs to be refactored for maintainability and to open up the development process. There's one guy in the world who really understands the codebase, so we're all one sleepy bus driver or bursting blood vessel away from vim becoming a frozen pile of code. Tarruda's starting point is refactoring out huge swathes of platform specific code, to be replaced with a single dependency on libuv for cross-platform support, to get to full test coverage, to modernize the C, and to craft a multi-developer process that allows for modern ongoing development by a large number of people, like other OSS projects have.
All the user focussed gains that will flow from that are real gains, but really what Tarruda is doing is freeing Moolenaar from the corner into which he's painted himself. I like to think that Moolenaar (like Stallman with JWZ's fork of emacs) will come around, see the real improvement in the fork, and arrange to cut over to it.
Re: (Score:2)
This kind of thing works from time to time when the original developers really aren't in sync with what's wanted or needed by the public. It worked with gcc -> egcs for instance, but most of the time its a waste of code and effort.
Re: (Score:2)
The problem with requiring C11 is that a lot of compilers don't support it. C99 support is getting better, but a lot of compilers are still lacking behind.
Have they talked to Bram first? (Score:2)
It's a pretty big step to just fork a major project like that. Have they actually talked to Bram and the other vim hackers first? I can only assume that if their ideas are sound that he would have no problem integrating them upstream.
Re: (Score:2)
Apparently Bram has already said that he thinks it's a bad idea.
A lot of the proposed changes are apparently to remove support for "obsolete" systems and configurations. It's really doubtful that it would ever be merged into the main vim codebase.
Re: (Score:2)
I see. Well, it's going to be interesting to see what comes out of it.
Re: (Score:2)
It's worth observing that Bram's vim started as an early 90s reimplementation of vi, which at the time was stuck in legal limbo due to its BSD origins. Vim eventually became the vi of choice for linux distributions, and was lifted by that rising tide to become what everyone now thinks of as vi. The vi that is considered a direct dependent of the original version written by Bill Joy is called "traditional vi".
If in five years, vi is typically a symlink to nvim instead of vim, I will be totally unsurprised.
Broken link (Score:2, Funny)
Re: (Score:2)
Re: (Score:2)
EMACS OTOH is increasingly getting replaced by all kinds of IDE's and what not. The number of new users are dwindling, it has no future.
*citation needed
You know it's time to modernize a program (Score:2)
Re: (Score:2)
Full blown vim in a good IDE:one of my dreams (Score:5, Interesting)
First class support for embedding
Since Neovim will be provide the interface to interacting with text, any program will be able to tap into this potential and be able to include Neovim commands right in the application.
Re: Full blown vim in a good IDE:one of my dreams (Score:2)
When I have some repetitive text I need to manipulate, I just copy-paste to vim, edit, and paste back into the IDE. Otherwise, I'm coding in the IDE. It's great.
Re: (Score:2)
Yes, but it would also have to be fast.
When I use Eclipse, Netbeans or Rubymine, I'm both impressed by the IDE features and angry at how sluggish simple operations are in comparison to vim.
I always fall back to vim.
Re: (Score:2)
While Sublime isn't quite a full-blown IDE, this integration with Vim might be closer to what you are talking about:
https://github.com/lunixbochs/... [github.com]
improve the scripting language (Score:2)
I think instead of rewriting the C part, they should improve Vim's scripting language to the point where it can be used for moving larger portions of the editor into it. Vim script is a decent effort, but it feels a bit cumbersome and non-standard. I think they'd be better off with something that more widely used and possibly JIT compiled.
While I like the idea of a modernized vim (Score:2)
I'm going to suggest that if you feel it's time to re-invent vim, that it target a universal platform. There's really only one - the web. You can use it on every platform. Using the project node-webkit, there's really no reason not to use HTML5 and Javascript to develop an honestly modern application. (The sarcasm is dwindling, I'm half serious
Re: (Score:2)
The problem is simply that vi/vim aren't meant for the 21st century and trying to shoehorn it in is a stupid idea.
You're really inexperienced in the wide range of places vi ends up.
vi as you know it, works the same on pretty much EVERY unix at this stage, including tiny tiny embedded ones. I heard a rumor of which I'm entirely sure was false that its even been on one of nasa's creations floating around off in the cosmos.
You are not putting webkit on my raspberry pi, I want to see the text updated sometime
Re: (Score:2)
Re: (Score:2)
Just so long as no-one ports KDE to JavaScript. That really would be going too far [etotheipiplusone.com].
i will gladly use neovim (Score:2)
As long as it passes VSC5, I don't care. (Score:2)
As long as it passes VSC5, I don't care.
They could put antlers on the thing, as long as it continues to pass the POSIX conformance test suite Validation Suite for Commands version 5, it doesn't matter, my medulla will be able to still type the commands to operate it while I'm up in my cerebral cortex thinking about higher level problems than "will typing this command too many times give me carpal tunnel syndrome like RMS has from emacs use?" or "how an I get a graduate student to take dictation into an edit
To fix vi (Score:2)
You would have to break all the things that cause people to use it ... and then its not going to work the same on EVERY unix machine on the planet. vi's strength lies in the fact that as crappy as it is, its consistently crappy, the same way (vi feature set) across all machines, even the crappiest tiny embedded linux distro, to full server and desktops. I don't have to wonder what editor I'm going to have to find and use nor how it works.
Stop fucking with vi.
If you want a non-shitty editor, stop using a s
Re: (Score:2)
Do people in fact still argue about vim vs emacs?
It seems to me the the vim-vs-emacs wars ended in a stalemate decades ago, and everybody who participated is resigned to the fact that nobody will ever switch from one to the other. Meanwhile, all the young'ns are using IDEs anyway, and have only a vague idea what vim or emacs is, so they don't really care enough to argue about which is better.
Re:There's a reason people argue about vim and ema (Score:5, Informative)
I tried your scenario.
If play your boss and I exit with ':q', no problem. Your version is still there.
If I exit with ':wq', vim says: "E45: 'readonly' option is set (add ! to override)"
If I exit with ':wq!', vim says: "WARNING: The file has been changed since reading it!!!
Do you really want to write to it (y/n)?"
So I conclude that one of the following is likely the case:
a) your boss is was an idiot who would ignore a message ending with three exclamation points
b) you boss installed a bizarre custom vim config file that somehow allowed silent overwrites of modified files from readonly mode
c) your story is a fabricated troll
Re: (Score:3)
Your scenarios are way too complicated. It's simple as this: the boss didn't open the files in readonly mode.
Re: (Score:3)
I bet his boss used ZZ to exit all the time. It's the vi lazy way to save and exit, no questions asked.
I tried that, too. It still won't let you write in readonly mode without warning you.
Re:There's a reason people argue about vim and ema (Score:5, Funny)
My previous employer did work in CICS for years, he's well out of the development game now and a 'serial startup guy' as he likes to call himself.
He KNOWS how to code, or at least, once did, I've heard from enough people that knew what he did at some large companies and validate his skills.
He will straight up ignore every fucking popup window that gets in front of him and just next -> next -> next -> finish through (windows user now) everything, or click whatever button seems most obvious on the popup ... never reads anything.
We had a 'bug' in the installer I wrote. He and another 'old dude' who used to be on the xml standards committees (again, this guy has clout in technical circles of yester year). The bug was that it would reboot your machine, without asking you, during install if you had Outlook open and it would close ALL of your apps without prompting for saving or anything else ... (it was an outlook plugin, easier to not install with Outlook open than to tell people they need to restart outlook for reasons that will become clear shortly).
So after explaining that I never could get that to happen to me in my environment (was working out of the country at the time, getting to stand next to them and watch them wasn't happening and for some reason I can't recall, vmc wasn't really an option either) I finally got back to the office where I could watch the process, where I was waiting to see how my NSIS installer was magically making things like Excel and Word close without saving files ...
BOTH of them, got to the point where a popup came up and said 'Outlook is open, close outlook to continue ' and they'd just click next ... at which point the installer says, Outlook is still running ... a reboot is required to complete this installation, do you want to reboot now?' and they click next so fast I couldn't even stop them.
Better still ... when Excel started asking them if they wanted to save ... ON THOSE DIALOGS they fucking clicked NO, so fast I couldn't even say 'whoa, wait a second' their machine was already rebooting ... after they clicked AT LEAST 4 boxes from different applications trying to slow them down and prevent the mistake.
The bug, was a PEBKAC bug with a bit of ID10-T thrown on top. I had to physically remove the mouse from one of their hands and run the installer myself to get them to actually read the message that they claimed they weren't seeing.
Another related story. I'm an IT guy, I have all those same IT shitty users stories most of slashdot has :) My pet peeve (like many of us) is people who don't read the message, and my wife, who has known how much that pisses me off since at least 2001 when it became a bigger issue for stupid reasons at one job calls me up the other day from her new job.
They sent her an email that she needed to change her password, they rotate on 90 days intervals. Its a university with some sort of identity management system in place that syncs all their systems and password changes are done via a website, fairly common setup for a university it seems though I don't know the specifics of the software involved yet.
So she clicks the link, changes her password and then tries to go visit some research paper website they have internally for internal releases of research papers for internal review and discussion before submitting to more formal publications, so she gets there and it says something wrong with her login/password. It never asks for a login password, just says no. So my eyes, recognizing that kerberos and/or ntlm is in play here said to her 'look sweetie, I don't know your setup, but since its not prompting you for a password, I bet if you just logout and log back in, it'll work. (Windows 'auto-corrects' a lot of silly issues for kerberos stuff on login and of course reinitializes your authentication ticket at login so your
Re: (Score:2)
Re: (Score:2)
I love VIM because I can guide a user remotely through exactly what to type and know exactly what response they'll get without depending on them to click on the right button or highlight the correct piece of text.
Ever edited /etc/ppp/chat-secrets with an accountant over the phone blind?
Re: (Score:3)
Re: (Score:2)
You know you can just mount the file system of the remote host by sshfs, right?
Re: (Score:2)
Re: (Score:3)
It doesn't work as well as you might wish. X11 has, historically, not compressed well for remote graphical interactions. The problem is compounded when running X sessions over a VPN to a remote environment, and using the graphical environment hosted inside the GUI to the virtual machine manager.
I've found vim very useful when memory or resource squeezed. Emacs's tendency to leave temporary scattered copies of large edited files is particularly dangerous when trying to salvage database backups on a cramped p
Re: There's a reason people argue about vim and em (Score:2)
You should automatically check for tabs and refuse any commit that uses them.
Re: (Score:2)
You should/could also slap some mod lines at the start of your files. Ex:
# ex: set tabstop=4 expandtab smarttab softtabstop=4 shiftwidth=4:
# -*- Mode: tab-width: 4; indent-tabs-mode: nil; basic-offset: 4 -*- #
You could also just run it through a tidy program and a site-specific config if you really want to be a formatting nazi.
Re: (Score:2)
-- Real men leave their Xs in Texas, and
-- X11 is a waste of admin bandwidth; command line or bust.
Re: (Score:2)
As much as I love forwarded X11 apps, its rarely efficient over moderate to slow links. I can't justify using over 1Mbit of uplink traffic just to use my editor over the wire when even a VNC session is more efficient.
FYI, I've often run vncserver on a remote machine, forwarded 5900 over my SSH session and then viewed it locally to launch X11 apps. This has the advantage of not killing the apps if the link goes down. It saddens me a lot that X11 isn't as powerful or useful in these scenarios as VNC.
Re:There's a reason people argue about vim and ema (Score:4, Informative)
It's pretty obvious that you've never had to debug deployed embedded systems. This isn't ancient history buddy, it's something I have to do regularly. Certain fields have requirements that just aren't going to go away.
Re: (Score:2)
Pico (Score:2)
I'd fire anyone that installed Nano (or, heaven forbid, Emacs) on an embedded device.
That's unfortunate for me because I prefer Nano. But I understand that the GNU project has made a design choice to optimize for functionality and maintainability on PCs, not necessarily the smallest devices. How small is such an "embedded device"? And is Pico (Alpine Composer), the editor on whose user interface Nano was based, likewise too big?
Re:Never understood the modes (Score:4, Insightful)
Vim is nice and I actually use it for programming, but jumping between the command mode, insert mode and visual mode still slows me down a lot. Why can't we just be in insert mode constantly and use Ctrl+something for all the commands? Also use Shift+arrows to select text?
Re: (Score:2)
Because it's smaller on embedded (Score:2)
If you don't care for the modes, why do you still use VIM?
This anonymous poster [slashdot.org] claims that his employer mandates a stripped-down version of Vim because it's smaller than GNU Nano. This means it more comfortably fits into the memory of a small embedded system to which someone connects through an RS232 terminal.
Re:Never understood the modes (Score:5, Interesting)
Vim isn't about typing. It's about manipulating text. Some of which involves typing and that's why it has insert mode, but a lot of it is about finding your place in a document or moving one block of text from one area to another area, or changing all of something into something else according to a pattern, and you can do all of this without taking your hands off of the keyboard.
Why, oh WHY, do those #?@! nutheads use vi? [viemu.com] makes a pretty reasonable argument.
Re: (Score:2)
Re: (Score:2)
Personally speaking, hitting 'i', 'e', 'esc' isn't that hard. I'm much more likely in those cases to have run the text through spell check and fold with 'v' and '!'.
Re: (Score:2)
Re: (Score:3)
Vim is nice and I actually use it for programming, but jumping between the command mode, insert mode and visual mode still slows me down a lot. Why can't we just be in insert mode constantly and use Ctrl+something for all the commands? Also use Shift+arrows to select text?
Vi was originally designed to run over a very slow modem - say 300 baud over a device with minimal keyboard (no arrow/cursor keys).
Once an editor gains a certain degree of power, you run out of Ctrl+ keys.
My gripe with the vi approach is that it assumes that commands are the rule and text entry is the exception. Most other editors - including the ones I grew up with - are of the opposite point of view.
Re: (Score:2)
The general idea is that you stay in Normal Mode (what you called 'command mode'). Insert mode is only ever entered temporarily, for short bursts of input; the (or Ctrl+[, as you seem to like keychords) to go back to Normal Mode should become second nature. You should never have to ask yourself "What mode am I in, right now?".
Visual mode, OTOH, is rarely a mode to switch to (one exception would be the rectangle-select (Ctrl+Shift+V)).
Re: (Score:2)
the (or Ctrl+[, as you seem to like keychords) to [...]
the <Esc> (or Ctrl+[, as you seem to like keychords) to [...]
FTFM
Re: (Score:2)
You're doing it wrong... as I was, until someone pointed out that command mode is normal mode. You don't sit in insert mode and jump to command mode, you sit in command mode, manipulating text and moving around, switch into insert mode to add text, and then immediately switch back to command.
Once you get used to doing that, vim suddenly makes a ton more sense, and you start using the keystroke combos to do things much more quickly than before. And the secret to jumping easily from insert to command mode i
Re: (Score:2)
That only makes sense in some bizarro world where your primary use of a text editor isn't adding text.
I'm not sure what development you do, but I'm not really that good at cutting and pasting blocks of text to create entirely new works.
I find it odd that you think its perfectly acceptable to spend most of your time in your editor not adding text, but rather fiddling with it and moving it around.
I'm fairly certain that you're doing it wrong. The guy you're replying to may be as well, but if you spend more t
Re: (Score:2)
If I'm entering a lot of text, then I'll stay in insert mode, typing away, backspacing to delete and tabbing to indent if auto-indent doesn't do it right. What you're missing is that most software development isn't about entering text. It's about reading existing code to understand the landscape, it's about refactoring code by moving chunks around or renaming things or adding comments here and there, it's about searching and finding, it's about structuring the code or grasping that structure. Unless you'
Re: (Score:2)
Why can't we just be in insert mode constantly and use Ctrl+something for all the commands? Also use Shift+arrows to select text?
If you have any issues with RSI, then vim is by far the best editor (especially the GUI mode version).
The command mode allows you to formulate in your mind what you want to do, and accomplish it in the minimum possible key strokes. This is important because your brain won't wear out like your joints and tendons can. The command mode usually allows you to specify repeat counts to avoid repeatedly mashing keys. It lets you make common text selections such as words, nested brackets, statements, etc with a coup
Re: (Score:2)
I probably spend more time in command mode than insert mode when I'm using vim to write code. That says to me that keeping an editor always stuck in insert mode may not be the best idea.
It's not that bad idea. After all, insert mode is where most of the actual code writing happens.
Re: (Score:2)
Not really. Most code is highly repetitive, and I typically copy far more words than I type out. I use various shortcuts to create most of the common syntax constructs of the languages that I use.
Moreover, developing software is usually an iterative process, where more effort is spent on revising the code than on entering it.
My whole point was that normal mode is far more powerful than insert mode, and it allows you to accomplish many tasks with a small fraction of the typing you would need with only insert
Re: (Score:2)
Not really. Most code is highly repetitive, and I typically copy far more words than I type out.
You're doing it wrong, thats the problem.
If you're continually copy and pasting code to reuse it, you are most certainly doing it epically wrong.
Re: (Score:2)
I'm not copying and pasting. I'm using things like Ctrl-P to do code completion without having to type out the full name. Maybe I shouldn't have used the term "copy".
Re: (Score:2)
You can switch to Joe's Own Editor: Joe 3.7
Re: (Score:2)
That's called emacs. Go try it.
The rest of us like knowing that when we're in insert mode, nothing we type will be interpreted as anything but data -- unless we hit ESC.
Re: (Score:2)
That's called emacs. Go try it.
I have tried Emacs but the multi-level commands made me nauseous.
The rest of us like knowing that when we're in insert mode, nothing we type will be interpreted as anything but data
What value is there knowing that? You're just typing text and letters appear on the screen.
Re: (Score:2)
Yes, this.
Re: (Score:2)
Corners of the keyboard (Score:2)
Re: (Score:2)
You don't hit ESC plus another character all the time, you just tap it and return to the home row.
With Ctrl keys, you have to hold it and another character at the same time; that's completely different.
Re: (Score:2)
Re: (Score:2)
Vim has had a GUI for quite some time now, since 4.0 or so. It's called gVim and it's actually good.
Re: (Score:2)
Leaving the original alone is what tarruda is doing. Do you not understand how forks work?
Re: (Score:2)
You keep using that word. Notepad is "simple". This [peopleofhonoronly.com] is not. Powerful, yes. Simple, no.