Five tips for beginners to learn Vim

Source: Internet
Author: User

I've been trying to learn Vim for years. Now Vim is my favorite Linux text editor and the most popular open source tool for developers and system managers. I speak of learning, refers to the real meaning of learning. It's really hard to be proficient, so I just want to be proficient. I've been using Linux for so many years, and I'll just open a file, use the left and RIGHT arrow keys to move the cursor, switch to insert mode, change some text, save, and then exit.

But that's just the most basic operation of Vim. My skill level only allows me to use Vim in the terminal to modify the text, but it does not have any of the powerful text processing features I imagined. This makes it impossible for me to use Vim to play the role of the Pico and Nano.

So why do you learn Vim? Because I spend a lot of time editing text, and I know there's a lot of room for productivity improvements. Why not choose Emacs, or a more modern editor such as Atom? Because Vim is right for me, at least I have a little experience in using it. What's more, it's very important that I rarely encounter a system that I need to deal with without Vim or its weakened version (Vi). If you have a strong desire to learn about Emacs that is more powerful for you, I hope these suggestions for the same editor for Emacs will help you.

After spending a few weeks focusing on improving my Vim skills, the first suggestion I wanted to share was that I had to use it. Although this seems to be know why's answer, it is actually more difficult than the plan I expected. Most of my work is done on a Web browser, and every time I need to open and edit a piece of text outside the browser, I need to avoid having to open Gedit subconsciously. Gedit has been placed in my Quick Launch bar, so the first step is to remove the shortcut and replace it with Vim.

In order to learn Vim better, I tried a lot. If you are also looking to learn, here are some examples of recommendations.

Vimtutor

The best way to start learning is to use the app itself. I found a small app called Vimtutor, and when you're learning to edit a text it can teach you some basics, and it shows me a lot of basic commands that I've neglected over the years. Vimtutor usually find it in a place where Vim is available, and if you don't have vimtutor,vimtutor on your system you can easily install it from your package manager.

GVim

I know that not everyone agrees with this, but it's what makes me use Vim from the terminal to use GVim to meet my basic editorial needs. Opponents said GVim encouraged the use of the mouse, and Vim is mainly designed for the keyboard party. But I can quickly find the command I want through the GVim drop-down menu, and GVim can alert me to the correct instructions and then execute it by tapping on the keyboard. It's not easy to learn a new editor and then get stuck in an unresolved dilemma. Reading man's words every few minutes or using a search engine to remind you of the key sequences you use is not the best way to learn new things.

Keyboard table

When I moved to GVim, I found a keyboard "quick check table" to remind me that the most basic keys are convenient. There are many such tables available on the web that you can download, print, and paste somewhere around you. But for my laptop keyboard, I chose to buy a stack of sticky paper. These sticky notes are less than $10 in the United States, and you can always remind me when I use the keyboard to edit text and try new commands.

Vimium

As mentioned above, my work is done on the browser. One of the suggestions I found helpful was to use Vimium to enhance the use of Vim. Vimium is an open source plugin on the Chrome browser that allows you to quickly manipulate chrome with Vim's instructions. I found that I only used a few times to switch contexts using shortcut keys, as if they were more familiar with these shortcuts than before. The same extension is also available on Firefox, such as Vimerator.

Other people

There's no doubt that the best way to learn is to turn to someone you've explored before and give him advice, feedback, and solutions.

If you live in a big city, there may be a Vim meetup group nearby, or a #vim channel on the Freenode IRC. #vim Channel is one of the most active channels on freenode, which can help with your personal problems. It's fun to listen to people who are complaining or see people trying to solve problems they haven't met.

So, what's going on now? So far it's not bad. Whether the time spent on it is worth it is how much time it takes to save you. But when I find a new keystroke sequence to skip words, or some similar tricks, I often get unexpected surprises and happiness. Every day I can at least see, a little bit of return, is gradually worthy of the original pay.

There is more to learning Vim than just these suggestions. I like to guide people. Vim Advantures, an online game that moves using vim keys. And on another day I found a very magical virtual learning tool in vimgifts.com, which is probably what you really want: a small GIF to describe Vim operations.

Have you taken the time to learn Vim? or any program that requires a lot of keyboard action? Do you think these efforts are worth the tools that you have mastered after your hard work? Did the increase in efficiency meet your expectations? Share your stories in the comments section below.

Five tips for beginners to learn Vim

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.