Introduction

I’m continuing my 30-day Linux challenge as part of my preparation for the RHCSA exam and today’s article is all about a tool I was initially intimidated by but now find incredibly powerful: the vim editor.

If you’ve used vi, then vim will feel familiar but with more features, more flexibility and a smoother editing experience. vim stands for Vi IMproved and it's exactly that an enhanced version of vi that makes working in the terminal more efficient, once you understand the flow.

Whether you’re writing scripts, editing config files or just taking notes on a remote server, knowing how to use vim confidently will save you time, frustration and help you look like a pro.

Index

  1. What is vim
  2. Getting Started with vim
  3. Common vim Commands You will Use Daily
  4. Helpful Tips for New Users
  5. Real World Scenarios
  6. Industry Insight
  7. Bonus Recommendation
  8. Quick Summary

🧠 What is vim?

vim is a highly configurable, powerful text editor built for both speed and precision. It’s used directly in the terminal and is widely available on Linux systems.


🚀 Getting Started with vim

Open or create a file:

vim filename.txt

Just like vi, vim has three main modes:

  • Normal modefor navigation and commands
  • Insert modefor typing/editing text (i to enter, Esc to exit)
  • Command modefor saving, quitting, searching (: to start)

✨ Common vim Commands You will Use Daily

Action Command
Enter insert mode i
Exit insert mode Esc
Save changes :w
Quit vim :q
Save and quit :wq or ZZ
Quit without saving :q!
Delete line dd
Copy line yy
Paste p
Undo u
Redo Ctrl + r
Search /text
Replace word :%s/old/new/g

💡 Helpful Tips for New Users

  • Use vimtutor to practice interactively (type it in your terminal).
  • Turn on line numbers: :set number
  • Highlight search results: :set hlsearch
  • Mistyped something? Undo with u, redo with Ctrl + r
  • If you ever feel stuck, press Esc as it is your exit key.

🛠️ Real World Scenarios

  • Editing system files on a remote server via SSH
  • Writing Bash scripts directly in the terminal
  • Working inside Git commit messages
  • Configuring services like Nginx, Apache or cron jobs

🏭 Industry Insight

Why vim is used in real environments:

  • No dependency on GUIs; ideal for servers and containers
  • Lightweight and incredibly fast
  • Built-in on nearly every Linux distro
  • Powerful once you learn the shortcuts; many sysadmins and DevOps pros never leave it

Mastering vim gives you editor freedom, you won’t depend on external tools to get work done.


📦 Bonus Recommendation

Install a basic .vimrc config to make vim more beginner-friendly:

echo "set number\nset tabstop=4\nset expandtab\nsyntax on" > ~/.vimrc

This enables:

  • Line numbers
  • 4-space tabs
  • Syntax highlighting

✅ Quick Summary

vim can seem overwhelming at first but with just a little practice, it becomes a natural and powerful part of your Linux workflow.

The goal is not to master everything, it is to become comfortable enough to do real work efficiently. One small win at a time. You’ve got this!
Image description


I'd love to hear your thoughts, insights or experiences with Linux. Feel free to share and join the conversation [Connect with me on LinkedIn www.linkedin.com/in/techwithsana ]💜

#30dayslinuxchallenge #redhat #networking #cloudcomputing #cloudenginner #cloudarchitect #cloud #RHCSA #RHCE #RHEL #WomeninTech #Technology