update
This commit is contained in:
parent
7f695e44e7
commit
9c09b879c0
3
.vimrc
3
.vimrc
|
@ -22,6 +22,9 @@ so ~/.vim/config/plugins/tagbar.vim
|
||||||
so ~/.vim/config/plugins/airline.vim
|
so ~/.vim/config/plugins/airline.vim
|
||||||
so ~/.vim/config/plugins/nerdtree.vim
|
so ~/.vim/config/plugins/nerdtree.vim
|
||||||
so ~/.vim/config/plugins/ultisnips.vim
|
so ~/.vim/config/plugins/ultisnips.vim
|
||||||
|
so ~/.vim/config/plugins/easy-align.vim
|
||||||
|
so ~/.vim/config/plugins/instant-markdown.vim
|
||||||
|
so ~/.vim/config/plugins/markdown.vim
|
||||||
|
|
||||||
|
|
||||||
" Vim default
|
" Vim default
|
||||||
|
|
|
@ -8,6 +8,12 @@ call vundle#begin()
|
||||||
"call vundle#begin('~/some/path/here')
|
"call vundle#begin('~/some/path/here')
|
||||||
|
|
||||||
" let Vundle manage Vundle, required
|
" let Vundle manage Vundle, required
|
||||||
|
Plugin 'evidens/vim-twig'
|
||||||
|
Plugin 'tpope/vim-markdown'
|
||||||
|
Plugin 'suan/vim-instant-markdown'
|
||||||
|
Plugin 'dhruvasagar/vim-table-mode'
|
||||||
|
Plugin 'tpope/vim-haml'
|
||||||
|
Plugin 'christoomey/vim-tmux-navigator'
|
||||||
Plugin 'junegunn/vim-easy-align'
|
Plugin 'junegunn/vim-easy-align'
|
||||||
Plugin 'jelera/vim-javascript-syntax'
|
Plugin 'jelera/vim-javascript-syntax'
|
||||||
Plugin 'elzr/vim-json'
|
Plugin 'elzr/vim-json'
|
||||||
|
|
|
@ -3,26 +3,42 @@ colorscheme onedark
|
||||||
|
|
||||||
syntax on
|
syntax on
|
||||||
set mouse=a
|
set mouse=a
|
||||||
set ignorecase
|
|
||||||
set smartcase
|
|
||||||
set splitright
|
|
||||||
set autoindent
|
|
||||||
set relativenumber " show relative number lines
|
|
||||||
set number " but absolute number for current line
|
|
||||||
set showcmd
|
|
||||||
set encoding=utf-8
|
|
||||||
scriptencoding utf-8
|
|
||||||
|
|
||||||
" show whitespaces
|
""""""""""
|
||||||
set list
|
" search "
|
||||||
set listchars=eol:¬,tab:>\ ,trail:⋅
|
""""""""""
|
||||||
|
set ignorecase " ignore case
|
||||||
|
set smartcase " . only if not all in lowercase
|
||||||
|
set incsearch " show matches when typing pattern
|
||||||
|
set hlsearch " highlights matches
|
||||||
|
|
||||||
|
|
||||||
|
"""""""""""
|
||||||
|
" display "
|
||||||
|
"""""""""""
|
||||||
|
set splitright " split right instead of left
|
||||||
|
set autoindent " auto linebreak indentation
|
||||||
|
set relativenumber " show relative number for lines
|
||||||
|
set number " but absolute number for current line
|
||||||
|
set showcmd " show typed command
|
||||||
|
set encoding=utf-8 " set encoding
|
||||||
|
scriptencoding utf-8 " set encoding ??
|
||||||
|
set list " for next command
|
||||||
|
set listchars=eol:¬,tab:>\ ,trail:⋅ " characters to display instead of whitespace characters
|
||||||
|
|
||||||
" default fold method
|
" default fold method
|
||||||
set foldmethod=syntax
|
set foldmethod=syntax
|
||||||
|
|
||||||
|
" use filetype
|
||||||
|
filetype plugin on
|
||||||
|
|
||||||
" search path recursive
|
" search path recursive
|
||||||
set path+=**
|
set path+=**
|
||||||
|
|
||||||
" abbreviations
|
" abbreviations
|
||||||
ab tf tabfind
|
|
||||||
ab f find
|
" functions
|
||||||
|
" yank buffer "0 to clipboard
|
||||||
|
map <C-Y> :tabnew<CR>"0p:saveas /tmp/cclip.tmp<CR>:!cat % \| xclip -sel clip<CR>:!rm %<CR>:q!<CR>
|
||||||
|
" paste clipboard to buffer "0
|
||||||
|
map <C-P> :tabnew<CR>:.!xclip -sel clip -o<CR>ggdG:q!<CR>
|
||||||
|
|
|
@ -1,16 +1,30 @@
|
||||||
|
" words backwards with SHIFT-w
|
||||||
|
nnoremap <silent> W b
|
||||||
|
|
||||||
|
|
||||||
|
" INSERT mode -> go back to NORMAL mode
|
||||||
|
imap <silent> <C-J> <Esc>
|
||||||
|
|
||||||
" new tab
|
" new tab
|
||||||
nmap <silent> <C-t> :tabnew<CR>
|
nmap <silent> <C-t> :tabnew<CR>
|
||||||
|
|
||||||
" new line shortcut (ctrl+o)
|
" new line shortcut (ctrl+o)
|
||||||
nnoremap <silent> <CR> o<CR><Esc>
|
nnoremap <silent> ee o<Esc>
|
||||||
|
|
||||||
" switch windows
|
" switch tabs
|
||||||
" nmap <silent> <C-k> :wincmd k<CR>
|
nmap <silent> <C-h> :tabprevious<CR>
|
||||||
" nmap <silent> <C-j> :wincmd j<CR>
|
nmap <silent> <C-l> :tabnext<CR>
|
||||||
" nmap <silent> <C-h> :wincmd h<CR>
|
|
||||||
" nmap <silent> <C-l> :wincmd l<CR>
|
|
||||||
|
|
||||||
" bind window : scroll + cursor
|
" split windows
|
||||||
nmap <silent> <F10> :set scrollbind<CR>:set cursorbind<CR>
|
nnoremap <silent> <C-W>\| :vnew<CR>
|
||||||
nmap <silent> <F12> :set noscrollbind<CR>:set nocursorbind<CR>
|
nnoremap <silent> <C-W>= :new<CR>
|
||||||
|
|
||||||
|
" bind windows: scroll + cursor
|
||||||
|
let bounded_wins=0
|
||||||
|
nmap <silent> <F12> :if (bounded_wins%2 == 0) \| set scrollbind \| set cursorbind \| else \| set noscrollbind \| set nocursorbind \| endif \| let bounded_wins=bounded_wins+1<CR>
|
||||||
|
|
||||||
|
" autoread (real-time changes)
|
||||||
|
nmap <silent> <F9> :set autoread<CR>
|
||||||
|
|
||||||
|
" reloads file
|
||||||
|
nmap <silent> <F5> :e!<CR>
|
||||||
|
|
|
@ -0,0 +1,5 @@
|
||||||
|
" Start interactive EasyAlign in visual mode (e.g. vipga)
|
||||||
|
map ga <Plug>(EasyAlign)
|
||||||
|
|
||||||
|
" Start interactive EasyAlign for a motion/text object (e.g. gaip)
|
||||||
|
map ga <Plug>(EasyAlign)
|
|
@ -0,0 +1,10 @@
|
||||||
|
" to update only when some events occurs (not real-time)
|
||||||
|
let g:instant_markdown_slow = 1
|
||||||
|
|
||||||
|
" launched on startup if markdown
|
||||||
|
let g:instant_markdown_autostart = 1
|
||||||
|
|
||||||
|
" allow external content (images, etc)
|
||||||
|
let g:instant_markdown_allow_external_content = 1
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,2 @@
|
||||||
|
" consider *.md as markdown files
|
||||||
|
autocmd BufNewFile,BufReadPost *.md set filetype=markdown
|
|
@ -0,0 +1,58 @@
|
||||||
|
|
||||||
|
snippet comh
|
||||||
|
/**nippet definition.***********************
|
||||||
|
* ${1:Program Name} *
|
||||||
|
* ${2: Date} *
|
||||||
|
***************************
|
||||||
|
* Designed & Developed by *
|
||||||
|
* xdrm-brackets *
|
||||||
|
***************************
|
||||||
|
* https://xdrm.io/ *
|
||||||
|
**************************/
|
||||||
|
$0
|
||||||
|
snippet comc
|
||||||
|
/* [${1:Number}] ${2:Chapter Title}
|
||||||
|
=========================================================*/
|
||||||
|
$0
|
||||||
|
snippet comcc
|
||||||
|
/* (${1:Number}) ${2:Chapter Title}
|
||||||
|
---------------------------------------------------------*/
|
||||||
|
$0
|
||||||
|
snippet coms
|
||||||
|
/* (${1:Number}) ${2:Section Title} */
|
||||||
|
$0
|
||||||
|
snippet comss
|
||||||
|
{${1:Number}} ${2:Section Title} //
|
||||||
|
$0
|
||||||
|
snippet comf
|
||||||
|
${1:RESUME DE LA FONCTION}
|
||||||
|
*
|
||||||
|
* @${2:nomParam}<${3:typeParam}> ${4:Description du param}
|
||||||
|
*
|
||||||
|
* @return ${5:nomRetour}<${6:typeRetour}> ${7:Description du retour}
|
||||||
|
*
|
||||||
|
*/${8:}
|
||||||
|
$0
|
||||||
|
snippet comcf
|
||||||
|
/* [${1:Number}] ${2:Chapter Title}
|
||||||
|
*
|
||||||
|
* @inputname<inputype> inputdesc
|
||||||
|
*
|
||||||
|
* @return outputname<outputtype> outputdesc
|
||||||
|
*
|
||||||
|
=========================================================*/
|
||||||
|
$0
|
||||||
|
snippet comccf
|
||||||
|
/* (${1:Number}) ${2:Chapter Title}
|
||||||
|
*
|
||||||
|
* @inputname<inputype> inputdesc
|
||||||
|
*
|
||||||
|
* @return outputname<outputtype> outputdesc
|
||||||
|
*
|
||||||
|
---------------------------------------------------------*/
|
||||||
|
$0
|
||||||
|
snippet comt
|
||||||
|
/************************************************
|
||||||
|
****${1: Titre }****
|
||||||
|
************************************************/
|
||||||
|
$0
|
Loading…
Reference in New Issue