-
Notifications
You must be signed in to change notification settings - Fork 9
/
vimrc
80 lines (65 loc) · 2.19 KB
/
vimrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
" Para poder cargar los plugins con Pathogen
call pathogen#infect()
call pathogen#runtime_append_all_bundles()
call pathogen#helptags()
filetype plugin indent on
syntax enable
" conf del editor
set nocompatible
set expandtab
set tabstop=2
set shiftwidth=2
set autoindent
set smartindent
set encoding=utf-8
set cursorline
set numberwidth=5
set clipboard=unnamed
"colorscheme zen
colorscheme vibrantink
" Toggle spell checking on and off with `,s`
let mapleader = ","
nmap <silent> <leader>s :set spell!<CR>
" Set region to casteñano español
set spelllang=es_ES
let php_baselib = 1
let php_htmlInStrings = 1 " para ver resaltado html en php
let php_parent_error_close = 1 " Genera error con mala sintaxis en las llaves
"Mapeo para las pestañas
:nmap <C-t> :tabnew<CR>
:nmap <C-p> :tabprevious<cr>
:nmap <C-n> :tabnext<cr>
" Mapeo para el browser
:map <C-m> :NERDTreeToggle<CR>
:map <C-c> :NERDTreeClose<CR>
" drush TODO
:map <F2> :Ddc<cr>
:map <F3> :Ddw<cr>
" Buscador de funciones
map <C-f> <Plug>ShowFunc
map! <C-f> <Plug>ShowFunc
if has("autocmd")
" Set Drupal files as php
augroup module
autocmd BufRead,BufNewFile *.module set filetype=php
autocmd BufRead,BufNewFile *.php set filetype=php
autocmd BufRead,BufNewFile *.install set filetype=php
autocmd BufRead,BufNewFile *.test set filetype=php
autocmd BufRead,BufNewFile *.inc set filetype=php
autocmd BufRead,BufNewFile *.profile set filetype=php
autocmd BufRead,BufNewFile *.theme set filetype=php
augroup END
" Source vimrc file after saving it
autocmd bufwritepost .vimrc source $MYVIMRC
endif
au BufRead,BufNewFile jquery.*.js set ft=javascript syntax=jquery
autocmd FileType php set omnifunc=phpcomplete#CompletePHP
autocmd FileType python set omnifunc=pythoncomplete#Complete
autocmd FileType javascript set omnifunc=javascriptcomplete#CompleteJS
autocmd FileType jade set omnifunc=javascriptcomplete#CompleteJS
autocmd FileType html set omnifunc=htmlcomplete#CompleteTags
autocmd FileType css set omnifunc=csscomplete#CompleteCSS
autocmd FileType xml set omnifunc=xmlcomplete#CompleteTags
autocmd FileType c set omnifunc=ccomplete#Complet
let g:SuperTabDefaultCompletionType = "<C-X><C-O>"
set gfn=Monaco:h12