is "vi" worth learning in 2022?

It took nineteen days for me to realise that neither of us disagreed about the second use of the word (to describe the merge experience, which typically drops the user into vi) …
 

Attachments

  • 1715125014543.png
    1715125014543.png
    140.5 KB · Views: 53
Last edited:
Basic vi is not difficult. It's a handful of key strokes; Esc, i, x, j, k, h, l, dd, a, A, / to search, and :wq! or ZZ to save and exit. In the worst case you can bail with :q! Anything else is optional. Best of all, it transcends all UNIXen and most look-alikes.
 
Let’s put “a cup of fresh water” in this thread:

What about next stack

(to install on remote server):
nvim (as alternative of micro/nano)
fzf
zsh
bat
delta
eza
tldr
thefuck
zoxide
atuin
zellij (as a server-side replacement of tmux or iTerm2)
mc

(to install on macOS)
iTerm2
Termius
SSH Config Editor

(to install on iOS)
Termius

?

P.S.
Mostly there are “new kids of the block” in CLI tools for SysAdmins that brings usability and speed into everyday work.
Of course You may prefer to stuck with old tool, but from professional point of view better to spend several days on learning new tool and as a result receiving more productivity and usability for next 3-5 years.

P.P.S.
As VPN client You may use VPN Tracker (+World Connect), or VyprVPN.
First are very flexible and support a lot of protocols and routers/fw, but EU-regulated so keep all logs of activity and use 3-rd party hardware infrastructure, second - also able to use own special Chameleon protocol to stay unrecognizable for DPI, own hardware servers, no any logs.
 
Invisible keyboard operations were targeting ANSI hardware terminals and serial connections. It's a waste of learning effort. Today, we have enough resources to do full visual text processing.
 
Invisible keyboard operations were targeting ANSI hardware terminals and serial connections.
You forgot about CLI which are 90-99% of any *nix professional work time.

Also this mean that MOST of this *nix users have special ergonomic keyboard (some make perfect customizable versions) and able to type without looking on it.

It's a waste of learning effort. Today, we have enough resources to do full visual text processing.
Computing resources is not the key in this case.
Muscular memory (at least for the most used commands and shortcuts) - that’s is the key!

And the second thing: for home/office You already have Apple iPad/iPad PRO that are perfect for ANYTHING. For photo/video producing, 3D, databases and programming - You need a powerful desktop.

And only for backend developing and servers/network admin work - You need just few monitors + keyboard + fast typing + useful software to accelerate Your skills.
 
It's a waste of learning effort. Today, we have enough resources to do full visual text processing.
(n)vi is a visual text editor. It is the visual mode of a line text editor (i.e ex).

I don't know too many guys who use non-visual line editors like ed, ex anymore day-to-day. I only do so in the OpenBSD ramdisk kernel to edit a custom fstab because (n)vi is part of the stripped /usr.
 
(n)vi is a visual text editor. It is the visual mode of a line text editor (i.e ex).

I don't know too many guys who use non-visual line editors like ed, ex anymore day-to-day. I only do so in the OpenBSD ramdisk kernel to edit a custom fstab because (n)vi is part of the stripped /usr.
I don't agree. Vi can have different 'states' which look exactly the same. In my opinion unnecessary. Any system is beyond that. This originates from terminals with limited hardware-based screen capabilities.

I could use vi in a serial terminal that lacks any curses-like support in very rare cases. That's really it. If it's a lot to edit, I probably still only echo text to files.
 
Vi can have different 'states' which look exactly the same.
They look the same because, as a screen editor, all of Vi's states are visual. Otherwise, only Ex would exist.

The 'V' in Vi even stands for 'Visual'.
I could use vi in a serial terminal that lacks any curses-like support in very rare cases.
No. You would have to use Ex as fallback. Luckily, most serial terminals support curses, as far back as the vt100 and beyond. I find the terminfo database itself quite amusing to flick through to see all the different ancient hardware.

This originates from terminals with limited hardware-based screen capabilities.
And more importantly, limited by the corresponding transport (i.e telnet, rsh, ssh). Ultimately, the transport hasn't gotten much better. SSH is still widespread.
 
True.
Command line usage even pre-dates it. I'm under the impression that even today the command line is still being used, efficiently & effectively.
I recently bought a Amstrad Joyce computer for fun. It boots VMS from floppy. Really disappointing this wasn't a thing in Europe 80's. I was used to MS-DOS command shell. That was total garbage compared to already existing interfaces like this.
 
Vi can have different 'states' which look exactly the same.
Because of this last years there are some kind of “shift” to improve UI of editors like vi.

I could use vi in a serial terminal that lacks any curses-like support in very rare cases. That's really it. If it's a lot to edit, I probably still only echo text to files.
Please, spend 15min (like time to enjoy a cup of good brew coffee) to trying NeoVim!
 
True.
Command line usage even pre-dates it. I'm under the impression that even today the command line is still being used, efficiently & effectively.
CLI usage are still alive because this 2 (two) main reasons:
1. MOST operations and servers maintenance better (quick, flexible and informative output) doing by CLI;
2. UI of CLI-oriented tools AND UI of server’s BMC, routers OSs still ugly, buggy and less flexible till now; (and because short period of “design-testing-prod” and needs to eliminate costs this situation would be still…)
 
I think, that is because you can use vi with a CRT Terminal, and not with a TTY, except as ex.
Exactly. Though what is quite amusing is ex (and its precursor, em) were actually considered visual editors back in the early 80's. This is because you could go back and edit your single line, interacting with the program directly (via raw mode). Yes, in i.e ed, the terminal could handle a backspace, but the program would be unaware of it.

Edit: Found original info I was referring to with "visual editing":


Its not only Microsoft Visual Studio using a very questionable term of "visual" ;)
 
Did 5 mins. What's wrong with backspace? Here we go. I have to read docs because I'm trying a anti-intuitive text interface...
Kids learning how to copy and paste at school with ctrl-c, ctrl-v spend a lot longer than 5 minutes for Microsoft Notepad to become "intuitive". They spend a whole 40 minute lesson at least!

Plus why strive for "intuitive"? We should strive for "innate" text editors. Babies coming out of the womb should immediately be able to use this stuff in 2024!
 
Plus why strive for "intuitive"? We should strive for "innate" text editors. Babies coming out of the womb should immediately be able to use this stuff in 2024!
And if it fails we blame it on the babies. Or chemtrails. Or $CURRENT_EXCUSE, but god forbid we blame the root cause - like that in order to do complex things you need complex tools.

To quote Sir Terry Prattchet: "All a dwarf needs is his mining pickaxe and some means of making fire. With that he can mine some ore and smelt some metal. With that he can make simple tools. And with simple tools he can make complex tools. And with complex tools, a dwarf can make everything."

The UI of any tool can be considered a language, and maybe the language of your mind (how you think) is too far away from the language of the tool to map efficiently onto it. (This is also how I would explain autism. Your mind does not map to the environment that is made for joe sixpack.)

That's it. Simply try to learn vi, and if you grok it - more power to you. If you don't, there is a load of different editors out there. But you don't need to force it, so maybe a better title would be "try to learn vi", because it is totally ok not to do this.
 
Kids learning how to copy and paste at school with ctrl-c, ctrl-v spend a lot longer than 5 minutes for Microsoft Notepad to become "intuitive". They spend a whole 40 minute lesson at least!

Plus why strive for "intuitive"? We should strive for "innate" text editors. Babies coming out of the womb should immediately be able to use this stuff in 2024!
One of the first computer problems that people remember is probably that the arrow keys do something that has no obvious relation with directions.
 
One of the first computer problems that people remember is probably that the arrow keys do something that has no obvious relation with directions.
True. Many people expected the arrow keys on the i.e Windows desktop to move the mouse in the direction they press.
This is one of those "intuitive" things that make sense but would ultimately be of very limited use. I suppose this is why Microsoft decided "Mouse Keys" should be disabled by default. (ironically its main use of that setting now is to ensure a mouse cursor still appears when using VNC on a headless windows box).

That said, there are loads of platform inputs that don't even have arrow keys. I think text editors like Vi/Vim supporting both is the best option. Microsoft Notepad would end up being frustrating, reaching for the mouse (Like Plan 9's ACME) just to navigate a few characters around.
 
Back
Top