vi, vim: 3 Decades Pile of History

Buy Xah Emacs Tutorial. Master emacs benefits for life.
,

spent a couple of hours looking at vim keys. It is, 3 decades pile of sh�t. Sorry, but truely. 〔➤ Emergency vi (vi tutorial)

terminal ADM-3A
The ADM-3A terminal, where vi's keybinding originated. 〔➤ History of Emacs & vi Keys (Keyboard Influence on Keybinding Design)〕 (img src)

i will never recommend emacs “evil-mode” again. (sometimes in past year i started to casually also recommend “evil-mode”, out of politeness with ergoemacs-mode. 〔➤ ErgoEmacs Keybinding: a Ergonomics Based Keyboard Shortcut System〕)

Actually, emacs isn't much better. Most default commands and keys are inefficient garbage. 〔➤ Why Emacs's Keyboard Shortcuts are Painful

if you just look at vi's {【i】, 【a】, 【o】} keys, you can see how inefficient and convoluted it is.

also, vim has 【p】 and 【P】 for paste. One pastes after the cursor, one pastes before. Ridiculous.

it's annoying but vi needs them because, when you move to end of line 【$】, then press 【i】 to insert, it'll insert before the last char on the line. The 【$】 really isn't moving to end of line, but to the position before the last char. (actually the whole thing is confusing, depending how you define “position”, as “between” chars, or “on” the char, and if “on the char”, you should have a consistent & universal useful way of always inserting before the position, or always after.)

there are several things wrong here. Better is:

(emacs is better here. It has one concept of “point” (aka cursor position), and the “point” is defined as the position between chars. The position before the first char is 1. Insertion commands always insert at “point”. (info "(emacs) Point") )

also, vi's copy/cut is one screwball. First of all, it uses the obsolete terminology “yank”, yet its use of the term “yank” isn't compatible with emacs's. Vi's “yank” is modern “copy”, and emacs's “yank” is modern “paste”. (In vi , you “yank” into clipboard. In emacs , you “yank” from clipboard. (vi's clipboard is called “register”, while emacs's is called “kill-ring”. Emacs also has a “register”, but it's a separate storage area. 〔➤ Emacs: Copy/Paste History, Multiple Clipboards, Register〕) )

So, right here, it's a confusion ball. No wonder unix/linux has a extremely bad reputation of being hard to use. (Note: it's not just hard to use, it is also utterly INEFFICIENT, despite the perpetual myth of being efficient or powerful. (vi & emacs are indeed more powerful than typical IDE or editors, but their power came from the command line nature (a command is a function that process strings in a programable way.). Given a editor with integrated command line system, both vi & emacs has the most INEFFICIENT keybindings.))

also, vim has “v” or 【Ctrl+v】 for “visual mode”. What's vim's “visual mode”? It's somewhat like emacs's “mark”, but one inconsistent ball. (i think vi doesn't have concept of mark, and vim (Vi iMproved) invented this “visual mode” concept. So, you have this situation where you have a bag of commands each ad hoc do one thing with no concept of text selection (what emacs call “region”), and when a new command is introduced in vim, it uses this “visual mode” concept to work on a region.)

there's no consistency to vim's keys neither. In vim, some commands are single key, some are with ⇧ Shift, some are 2 keys, some involves Ctrl. (In this regard, emacs is slightly better.)

another tell-tale sign how vi is convoluted is to look at how to do search or find/replace. Normally, the key 【:】 starts command, such as {【:help】, 【:set number】, 【:syntax on】, …}. But there's also 【:8】 to goto line 8, and 【:$】 to goto end of file, and 【G】 is also goto end of file, then you have 【:s/regex/replace/flags】 to do find/replace, then you have 【:20,30s/aa/bb/gc】 to do between a range of lines. And you have 【:q】 for quit, and 【:w】 for write (save), and you an do both by【:wq】, but 【:help】 isn't made of 4 commands 【:h】 【:e】 【:l】 【:p】. Then, you have 【:q!】, meaning quit without saving. (is there a perspective that can actually explain these as a coherent system?)

(in emacs, this is much better too. You have commands, and command may have keybinding. To call a command by name, press M-x. And, command has consistent mechanism of getting its arguments (arguments/parameters may specify behavior of the command, or which region to work on, or how many times to repeat, or user input (such as regex), etc.).)

if you look at vim's commands, say, from 【a】 to 【z】 and 【A】 to 【Z】, and 【Ctrl+‹key›】, you'll find half of them redundant, and the semantics convoluted. It'd be more efficient to just have a set of 【a】 to 【z】 keys, and mapped to commands according to finger ease and the frequency the command is needed. Rid of any capital case commands, or reserve them to less used commands.

currently i have a urge to create a vim init file that emulates ergoemacs-mode… (btw, it already exists, see: 〔ErgoVim Key Mappings By Harrison Ainsworth. @ www.hxa.name…〕.)

the last time i looked at vi seriously is around 1998. I found it intolerable. (i was a big GNU fanatic and unix-hater as captured in the acronym “Gnu is Not Unix”) Today, i thought of getting myself proficient with vim, but, now am not willing to proactively do so.

can vim be better? Sure, it can be much better, far more efficient. But, will vim throw away its backward compatibility? Likely not. Will vim throw away its outdated terminologies? No, because those are cuddly points of cult pride. Same with emacs.

Like it?
Buy Xah Emacs Tutorial
or share
blog comments powered by Disqus