Guest User

Untitled

a guest
Dec 4th, 2018
122
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
VIM 1.58 KB | None | 0 0
  1. set nocompatible
  2. syn on
  3. set number
  4. set tabstop=4
  5. set shiftwidth=4
  6. set autoindent
  7. set showmode
  8. set showcmd
  9. set ruler
  10. set backspace=start,indent,eol
  11. set wrapscan
  12. set incsearch
  13. set ignorecase
  14. set tags+=tags;
  15. set wildmenu
  16. set wildmode=longest,full
  17. set expandtab
  18.  
  19. let mapleader = ","
  20. nnoremap <leader>t :TagbarToggle<CR>
  21. nnoremap <leader>u :GundoToggle<CR>
  22. nnoremap <leader>h <C-w>h
  23. nnoremap <leader>l <C-w>l
  24. nnoremap <leader>g <C-w><C-]><C-w>T
  25. nnoremap <leader>f :NERDTreeToggle<CR>
  26. filetype plugin indent on
  27. let php_folding = 1
  28. let php_sql_query = 1
  29. set foldmethod=syntax
  30. "set foldcolumn=3
  31. set foldlevel=2
  32. set hlsearch
  33.  
  34. set t_Co=256
  35. set term=screen-256color
  36. colorscheme zenburn
  37.  
  38. "“ Insert <Tab> or complete identifier“ if the cursor is after a keyword
  39. "character
  40. function MyTabOrComplete()    
  41.     let col = col('.')-1    
  42.     if !col || getline('.')[col-1] !~ '\k'        
  43.         return "\<tab>"    
  44.     else        
  45.         return "\<C-N>"    
  46.     endif
  47. endfunction
  48.  
  49. inoremap <Tab> <C-R>=MyTabOrComplete()<CR>
  50.  
  51. "Use H and L to switch between tabs
  52. :map <S-h> gT
  53. :map <S-l> gt
  54.  
  55. "Use Q to close tabs
  56. map <S-q> :q <Enter>
  57.  
  58. " This block is taken from the CentOS /etc/vimrc file. It
  59. " restores the last cursor position when you open a file to edit.
  60. " Only do this part when compiled with support for autocommands
  61. if has("autocmd")
  62.     augroup redhat
  63.         "When editing a file, always jump to the last cursor position
  64.         autocmd BufReadPost *
  65.         \ if line("'\"") > 0 && line ("'\"") <= line("$") |
  66.         \   exe "normal! g'\"" |
  67.         \ endif
  68.     augroup END
  69. endif
Add Comment
Please, Sign In to add comment