Ten years ago I threw out my massive multi-file, multi-package vim config and have been slowly building up a much simpler vimrc about 1-2 lines a year. I completely agree, defaults in old software are almost always there for a reason and you should try to understand that before changing them.
That would be true if you had universally great designers back then, which wasn't the case, thus the defaults are universally bad, so it's a bad heuristic to stick to them and force a waste in trying to understand them.
For example, why is the default vim cursor hjkl? Well, it's just that the arrows on the physical keyboard of one of the vim designers were drawn there. That's it. There is no deep thought in search of the best cursor position, and understanding the why is just learning a useless piece of trivia.
That seems quite harsh. Just because the designers aren’t perfect doesn’t mean the design is universally bad.
To address your example: Why were the arrow keys on those particular keys? Who put them there? hjkl are on the home row, and touch typists end up having the movement keys under their right hand’s resting fingers. That’s suddenly quite convenient.
> and touch typists end up having the movement keys under their right hand’s resting fingers.
This is false, h isn't in the resting place. So go back and spend more time trying to explain that historic tidbid of design before trying to defend it (I'd also be curious to know why they shifted left instead of using resting places)!
Or don't and use this obvious principle directly and change keybinds to jkl;
Or go with the muscle memory of inverted T and use ijkl
But whatever you do, prioritizing the original design is a common bad heuristic because there is no reason to think that the original designer was great (not perfect!, don't twist it), so trying to understand the original reasons is a waste of "productivity" time (but if you're curious, it's not a waste of regular time)
As pointed out, this is wrong. What touch-typists want is jkl;, because the right home key is j. This is an absolutely necessary config change in vanilla vim, unfortunately.
For me personally is the J/K direction still feels swapped and I always have to remind myself they are in fact the other way round. Even (especially) for touch typists, I would really expect [k] to point down and [j] up. In our writing system from the top left to bottom right my intuition would really be to stick ↑ with ← together and vice versa ↓ with →.
← ↓ ↑ →
makes a little sense to me.
← ↑ ↓ →
would be way better, IMO.
Not only because the most used used direction (↓) would be closer to my "neutral" finger position, but mainly because the the keys for progressing "back" and keys for progressing "forwards would be grouped together.
Honestly, I wouldn't even mind having them spread across two rows, like U I J K
↑ ↓
← →
or something. (Personally, I have global WASD-like arrow mapping bound to IJKL through capslock combo in AutoHotkey, since sometimes cursor keys are really inconveniently far away when typing.)
I think the current system is the way it is in order so that the most used direction (down) uses your strongest finger, the index finger.
I don't know what your mean by "Not only because the most used used direction (↓) would be closer to my "neutral" finger position" - what is your neutral finger position?
I also got lost in the sentence about "back" and "forwards" - what is back and forwards?
I like the bindings, because I move vertically more than I move, so I want my strongest (other than the thumb) there. And I move to the right more than I do to the left. So I don’t mind moving my finger to do the latter.
It may be different based for others based on hand anatomy, but at least for me the index finger is so much stronger than the little finger, that it feels more comfortable moving it one space to the left, especially on keyboards with heavy keys (like model M).
I will admit that I had never considered things like this (there's a couple of you making a similar point). It's a decent argument. Maybe I'll revert to the default and see if I can handle the change.
As a touch typist that learned decades before learning vi, with Emacs in the middle, I can definitively say your blanket statement is false. And as a recovering Emacs user, I can also say the little finger thing for a repetitive key is a dangerous proposition with real potential health drawbacks.
The fact that the tools have survived and are still used today is at least somewhat indicative of their quality though. A lot of worse designs have likely been selected away due to nobody even bothering to use them.
P(old thing being good | old thing still being used after N years) is pretty high. Certainly higher than the base rate of P(new design fad being good).
> defaults in old software are almost always there for a reason
Keeping your fingers on the home row is great design for keyboard-first navigation.
All software design is historically contingent so you do have a point but assuming that old design = bad design is just wrong. Some things haven't changed.
> Keeping your fingers on the home row is great design for keyboard-first navigation.
Except you've just made that reason up since vim's defaults don't follow this logic. For example, the most frequent commands of going back/forward by word are not on the home row, they follow a different principle of name-based mnemonics.
Strictly speaking, this isn't even true for hjkl, that was due to the fact that arrows were drawn there, not because the designer followed some good design principles (granted, at least the physical arrows were likely driven by that principle, though there is still a mistery of moving off resting/home keys, which might be related to the fact that cutoff ASCII H code is backspace https://news.ycombinator.com/item?id=3684763).
> Some things haven't changed.
Indeed, and that universal fundamental thing that hasn't changed is that a few random people doing design blindly can't universally create a world of good design!
Yes, they are not in the resting position on the home row, but they are close enough for a command you will be executing often. Crating a key-map is an optimization problem between memorability and ergonomics.
Vim command layout is not perfect, the worst offender in my opinion is $ (move cursor to the end of the line), which is commonly needed, but somewhat hard to reach.
HOWEVER - when you start to use an surviving piece of still used old software, a bit of humility goes a long way. Not because software or designers were necessarily better in the past, but the reason that the software is still in use is probably because there are some benefits to it. So learn the defaults first, modify later when you understand them.
> they are close enough for a command you will be executing often
Right, just like w/b are "close enough" outside the home row completely
> but the reason that the software is still in use is probably because there are some benefits to it.
You forgot to connect this principle to this discussion. How does it make the defaults good to support your faulty conclusion that you need to learn them first?
> Right, just like w/b are "close enough" outside the home row completely
Yes, they are close enough, and w/b are executed often.
> How does it make the defaults good to support your faulty conclusion that you need to learn them first?
You need to at least study them because assuming a priori that they are either good or "universally bad" is a faulty conclusion - and some stuff doesn't become obvious until you use them for some time.
When you start learning VIM, you will be faster with arrow keys, because you are used to them from other programs. When you get enough muscle memory, you may discover that there is some value in having somewhere near where your fingers rest on the keyboard - or maybe you will still find that you are faster with arrow keys - whatever the conclusion, it can not be made objectively before you have enough proficiency with both.
... one still can't correct the fault. You haven't answered the question of the original disconnect in arguments.
Your new arguments aren't relevant either since they're also NOT connected to the original re. bad defaults. You can have bad defaults that aren't there for any good reason and still think that reducing maintenance is more valuable! Fine, but that's a different argument!
Lets go one level deeper: What's the reason that the vim disgners keyboards had hjkl as arrow keys? Because it made sense for it to be the home row. I still use arrow keys though
No accounting for taste, but my similarly terse vim config includes relativenumber and number. Relativenumber is just so damn useful for doing things to larger chunks of code without having to count lines or anything.
I'm also an IDE user though. I tend to maintain a dichotomy between emacs(with evil-mode, of course) as the "kitchen sink" set up, with all the fixings, and vim with a config so short I can type it in as commands if I need to.
Vanilla vim is really perfect for quick edits to config files, scripts on random servers/VMs etc.
Bigger projects, at least for my usage, all happen on the same system , and having a bit more involved of an emacs set up makes sense there.
I suppose one could do a similar dichotomy with vim/neovim, if one had a distaste for emacs.
… why `memory commit` what you can `git commit` and then just `git clone`.
(I keep most of my dotfiles in a repository called "dotfiles".)
I get the emotional value/desire for a minimalistic .vimrc, but I also need the usefulness, and that necessitates, e.g., pulling in some plugins. E.g., lang-servers are just so valuable for immediate feedback in the editor.
Over time, someone of my vimrc has been pruned away just by development that has happened in/on vim itself, which is always lovely to see.
I've done it. It was terrible. I'm glad the project ended.
There's no fixing it, though. I can know the "base tooling with zero config" … and I'm just less productive, that's all there is too it. Customized tooling makes me faster than the base tooling. (I did start trying to find "inventive" ways to try to work around the problem, of course. My case wasn't like military air-gapped or anything, just the only connection was via RDP. So for example, copy & paste is a communication channel.)
I mean there is a middle ground. LSP is good for coding a project. But I do agree with your point. What I generally do (as nvim user) reduces plugins to the bare minimum and try as much as possible to do progressive enhancement (atleast I try). Maybe as nvim improves LSP, I hope the diff between LSP and native methods are close enough that they both work.
I would love a generative llm script that looks at my command history (or something comparable), and adds a new zsh config (or other dotfile) every day, explaining itself via a reliable motd-type screen that flashes on-screen during the first session of the day, explaining what was added and allowing me to play with it and decide to keep it or not by the end of the day :)
Basically, slowly "evolving" my environment by forcing me to try new things daily, without my doing massive "learning" runs where I try batches of new things at once
A wise elder once advised me that if I learned to work quickly and comfortably with an application’s defaults, I would be just as quick and comfortable on any system I would likely encounter. Very zen. Great advice.
Seems like using a tool to its fullest potential to get more work done is better advice.
> I would be just as quick and comfortable on any system I would likely encounter.
How often are we encountering other systems…? And even where I am rarely ssh'd into something else … are we doing so much editing of code (live in production…?) that it matters? (I heavily customize my vim, but it isn't like I'm lost on a remote system with stock vim, or nano. ed is another matter.)
But if I need tons and tons of editing, … sshfs+local vim/terminal? But this just such a rare case, it seems like one of those "we should optimize for the common case" — which this is not.
I see it more as like understanding how to use a hammer even if most of the time in your job you use a nailgun.
For me personally it's a classic old timer habit from the days when you had to be prepared to fix a system using only the tools in /sbin. That doesn't mean you should operate like that all the time, but you should certainly know how to do so and be comfortable doing it.
Isn't the author likely to know the tool's potential best? I get that there are special cases but those should be few and ones you know well enough to memorize the exceptions for.
I also find creating my own little shortcuts to be super satisfying and of course very transferable since they work out of the box.
```some examples
" Quick access to commonly edited config files (and a directory for my Shell scripts!)
map <leader>v :e ~/.vimrc<cr>
map <leader>V :source ~/.vimrc<cr>
map <leader>w :e ~/Workspace/myCo/tmuxp-session.yaml<cr>
map <leader>W :e ~/.tmux.conf<cr>
map <leader>z :e ~/Shell<cr>
" Super simple in editor note setup, amazing
map <leader>x :vs<cr>:e ~/Documents/notepad.txt<cr>
map <leader>X :vs<cr>:e ~/Documents/notes<cr>
" Quick terminal pane
map <leader>t :vs<cr><c-w>l:term<cr><c-w>j:q<cr>
" Pull file path into clipboard
nmap <leader>b :let @+ = expand("%")<cr>
" Pull current line into clipboard
nmap <leader>B "*yy
```
Quick disposable terminals, tons of short cuts to get me into the config files that make it all happen (vimrc, zshrc, tmux.conf, a tmuxp session file) and to reload them, and super quick access to a well organized directory of notes are all huge boons during my workday.
Some defaults suck massively, emacs in tmux basically doesn't work due to hijacking C-b. The one that catches me every time is whatsapp that hijacks C-p.