Thursday, May 2, 2024
3
rated 0 times [  3] [ 0]  / answers: 1 / hits: 4518  / 1 Year ago, wed, march 1, 2023, 8:48:32

I was trying to learn working with vi, the plain 'vi' that ships with most of the operating system, but that 'vi' seems to be missing lot of features.

When I tried to excute ":ls", it gave me error E319: Sorry, the command is not available in this version.



Similarly for most of commands, When I tried :version, it returned Small version without GUI .

For now I just want to learn working with "vi" not "vim".




  • So any nice place where I can learn from(I found most tutorials are for vim).

  • Any easy ways to extend functionality of "vi" not "vim"

  • Any tips if I'm going on wrong path


More From » command-line

 Answers
5

The "vi" command that comes with Ubuntu is actually just linked to vim, with options that disable several of its features, putting it in a sort of "vi compatibility mode", the same as using the :set compatible command.



The original "vi" itself is ancient, and has a license that would not allow it to be distributed with Ubuntu. It has a number of spiritual successors in the form of open source editors that emulate it, but the most popular of these is vim, followed by nvi and elvis.




  • vim is the most popular successor to vi, and adds many helpful features, many which you are used to and probably think of as being part of vi, but in reality are features added to vim. vim aims for improved usability.


  • nvi is another editor that attempts to more closely emulate the original vi, but has since gone on to add many improvements.


  • elvis is another editor that attempts to closely emulate the original vi but add extra features. elvis is the vi-like editor used by Slackware Linux.


  • busybox is a multi-purpose executable that includes a vi-like editor, but also includes a number of other command line tools. It is designed for embedded systems and devices with very low memory or storage space. Its vi-like editor is a vi clone optimised for very low size and memory use.


  • neovim is a fork of vim intended to implement some features vim is seen to lack. It was once heralded as the new vim replacement but its growth has been slower than some hoped during initial enthusiasm about the project.




The reasons you're having problems is that you're trying to use vim commands in vim's "vi compatibility mode" which disables these features.



I don't see any value in limiting yourself to just the commands that were in the original vi, as that editor is not really relevant anymore and you may as well benefit from the increased usability and functionality of vim or one of the other clones.


[#22839] Wednesday, March 1, 2023, 1 Year  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
whipstder

Total Points: 189
Total Questions: 110
Total Answers: 99

Location: Uzbekistan
Member since Sat, Feb 27, 2021
3 Years ago
;