Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 

.vimrc file to auto color and indent for bash scripts


Important

Copy this as .vimrc in users home directory


" Enable Syntax Highlighting
syntax on

" Expose spaces as red dots
set listchars=space:.
highlight SpecialKey ctermfg=darkred
set list

" File Type Detection and Plugin Loading
filetype on
filetype plugin on
filetype indent on

" Set Default Tab Behaviour
set expandtab
set shiftwidth=2
set softtabstop=2
set tabstop=2

" Customise Settings for bash and sh
augroup bash_settings
  autocmd!
  autocmd FileType sh,bash setlocal shiftwidth=2 softtabstop=2 tabstop=2 expandtab
augroup END