[FreeBSD] How to install VIM editor in FreeBSD

[FreeBSD] How to install VIM editor in FreeBSD

By default FreeBSD comes in a command line user interface.
As an Administrator or a Device Drive developer or as a FreeBSD user, you must be having a good text editor in hand to work comfortably on a command line environment.

By default there are two such text editors installed under FreeBSD, such as: vi and ee.
There is no such drawback in these editors but VIM (Vi IMproved) is a feature rich text editor as compared to the others, such as: you can access multiple files simultaneously, search for keywords easily across files and many more.

Make sure you have a working internet connection on the system and ports collection installed.

How to Install VIM on FreeBSD:

For FreeBSD 8.4 and greater versions:
If you are on FreeBSD 8.4 or later, then you can use the next generation package management utility present in FreeBSD.
We will use the pkg utility and even the ports collection will also be useful but why to use a complex path when we have easy to use stuffs.
To install VIM on your machine, type the following command in the command line:

# pkg install editors/vim-lite

For FreeBSD version less than 8.4:
If you are on FreeBSD machine lower than 8.4 version, then you have to use the ports collection and if you don’t have, then the below link will help you out installing the ports collection:
How to Install Ports Collection on FreeBSD

Now find out where is the location of VIM editor sources that we are going to install.
To know type the following command:

# whereis vim-lite

Then move to the location:

# cd /usr/ports/editors/vim-lite

Type the following command to start installation:

# make install clean

The above step will first build the dependencies for, then install the VIM editor in your machine and after that it will remove the intermediate files generated while building VIM.

After successful completion of the above step type the vim command to see whether vim has installed or not.

$ vim

Learning VIM secrets:

You can check the manual page on your FreeBSD system to have a better idea on VIM editor.

$ man vim

To know more on VIM usage and some useful VIM commands, follow the below link:
Useful VIM commands

Previous Official Slim ROM for Nexus 4 Android Lollipop ROM
Next [ROM] CyanogenMod 12 ROM for Motorola Moto E codename: CONDOR Android Lollipop 5.0.2

About author

siba 698 posts

A B.Tech degree holder with more than 5 years of experience on Embedded Systems design domain. He has worked on Aerospace domain, NAND storage, Server storage and Wireless networking.

View all posts by this author →

You might also like

FreeBSD Guides 0 Comments

[FreeBSD] How to install ports collection manually in FreeBSD

As an Administrator or a Device Drive developer you may need some utilities on the go to work in a convenient environment. Let’s say you want to install VIM editor,

FreeBSD Guides 0 Comments

[How to solve] Could not load host key: /etc/ssh/ssh_host_rsa_key issue in FreeBSD or Linux

Sometimes while starting the sshd service you may face some issues like the following: Could not load host key: /etc/ssh/ssh_host_key Could not load host key: /etc/ssh/ssh_host_rsa_key Could not load host

FreeBSD Guides 0 Comments

[FreeBSD] How to set and unset loader variables in boot loader prompt

Important question is why you need to set and unset variables at boot time??? The answer is when something is stopping you from booting your system then this may help


No Comments Yet!

You can be first to comment this post!