Modify Vim configurations in Ubuntu and Ubuntu
In UBUNTU, the vim configuration file is stored in the/etc/vim directory. The configuration file name is vimrc.
Show row number
Syntax highlighting
Auto indent
Show commands in text
Show nearest matching brackets
Smart matching
Smart prompt and search
" The following are commented out as they cause vim to behave a lot" differently from regular Vi. They are highly recommended though."set showcmd " Show (partial) command in status line."set showmatch " Show matching brackets."set ignorecase " Do case insensitive matching"set smartcase " Do smart case matching"set incsearch " Incremental search"set autowrite " Automatically save before commands like :next and :make"set hidden " Hide buffers when they are abandoned"set mouse=a " Enable mouse usage (all modes)
Note: In the location file, you can use "Comments allowed"
Automatic highlighted code prompt
" Vim5 and later versions support syntax highlighting. Uncommenting the next" line enables syntax highlighting by default.if has("syntax") syntax onendif
Command Prompt code
" Uncomment the following to have Vim load indentation rules and plugins" according to the detected filetype.if has("autocmd") filetype plugin indent onendif
set nuset autoindentset cindent "this is main for C languageset tabstop=4set shiftwidth=4set softtabstop=4