Skip to content

Instantly share code, notes, and snippets.

@lzto
Created May 22, 2018 02:30
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lzto/39000a6f6d7a65d65260b6f1a77c4655 to your computer and use it in GitHub Desktop.
Save lzto/39000a6f6d7a65d65260b6f1a77c4655 to your computer and use it in GitHub Desktop.
" Vim5 and later versions support syntax highlighting. Uncommenting the next
" line enables syntax highlighting by default.
syntax on
"no compatible
set nocompatible
" If using a dark background within the editing area and syntax highlighting
" turn on this option as well
set background=dark
" jump to the last position when reopening a file
au BufReadPost * if line("'\"") > 1 && line("'\"") <= line("$") | exe "normal! g'\"" | endif
" load indentation rules and plugins according to the detected filetype.
filetype plugin indent on
"set show line number
set nu
"pathogen
execute pathogen#infect()
"show cursor line
set cursorline
" cursorline color
":highlight CursorLine ctermbg=LightBlue
" 80 characters each line
set colorcolumn=81
" column color
highlight ColorColumn ctermbg=Black ctermfg=DarkRed
" show existing tab with 4 spaces width
set tabstop=4
" when indenting with '>', use 4 spaces width
set shiftwidth=4
" On pressing tab, insert 4 spaces
set expandtab
" powerline, this should just work fine..
python from powerline.vim import setup as powerline_setup
python powerline_setup()
python del powerline_setup
" just in case it does not work...
" set power line symbol
let g:Powerline_symbols = 'fancy'
" for GUI
set guifont=Inconsolata\ for\ Powerline:h15
" Use 256 colours (Use this setting only if your terminal supports 256 colours)
set t_Co=256
" scrambled bar with ^B?
set encoding=utf-8
" scrambled bar with ^?
set fillchars+=stl:\ ,stlnc:\
" always show status bar
set laststatus=2
"terminal setup
set term=xterm-256color
set termencoding=utf-8
" set highlight search
set hlsearch
" auto regenerate taglist
autocmd BufWritePost *.cpp :TlistUpdate
autocmd BufWritePost *.c :TlistUpdate
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment