Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8258585
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T02:35:32+00:00 2026-06-08T02:35:32+00:00

How do you set up a .vimrc file on Ubuntu? This is not helping:

  • 0

How do you set up a .vimrc file on Ubuntu?

This is not helping: http://vim.wikia.com/wiki/Open_vimrc_file

  1. Where do you create it?
  2. Whats the format inside?

I know the stuff I want to put in it, just don’t know how.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-08T02:35:33+00:00Added an answer on June 8, 2026 at 2:35 am

    Where:

    On UN*X systems your .vimrc belongs in your home directory. At a terminal, type:

    cd $HOME
    vim .vimrc
    

    This will change to your home directory and open .vimrc using vim. In vim, add the commands that you know you want to put in, then type :wq to save the file.

    Now open vim again. Once in vim you can just type: :scriptnames to print a list of scripts that have been sourced. The full path to your .vimrc should be in that list. As an additional check that your commands have been executed, you can:

    • add an echo "MY VIMRC LOADED" command to the .vimrc, and when you run vim again, you should see MY VIMRC LOADED printed in the terminal. Remove the echo command once you’ve verified that your.vimrc is loading.
    • set a variable in your .vimrc that you can echo once vim is loaded. In the .vimrc add a line like let myvar="MY VIMRC LOADED". Then once you’ve opened vim type echo myvar in the command line. You should see your message.

    The Format:

    The format of your .vimrc is that it contains Ex commands: anything that you might type in the vim command-line following :, but in your .vimrc, leave off the :.

    You’ve mentioned :set ruler: a .vimrc with only this command looks like:

    set ruler
    

    Search for example vimrc and look over the results. This link is a good starting point.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is it possible to set in .vimrc that vim saves the file every time
In my .vimrc file, I have this line: set mouse=a This enables the mouse
When I put in my .vimrc file: set backspace =2; set nocompatible; syntax on;
In my .vimrc, I set different makeprg according to the source file type as
I use the syntax foldmethod in vim 7.3. In .vimrc: set foldmethod=syntax When I
I set up this mapping in my .vimrc and it works great... Auto indent
I am trying to set up a .vimrc file in my home directory. The
I have auto indentation turned on in my .vimrc file set autoindent which moves
I wrote set tw=0 into my .vimrc file. But when I verify options with
I added: set number nnoremap <F2> :set nonumber! to my vimrc file. Basically what

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.