Skip to content

Instantly share code, notes, and snippets.

@nongiach
Last active July 7, 2019 11:28
Show Gist options
  • Select an option

  • Save nongiach/aa7db2294c7466daf9496a5bf4ca6439 to your computer and use it in GitHub Desktop.

Select an option

Save nongiach/aa7db2294c7466daf9496a5bf4ca6439 to your computer and use it in GitHub Desktop.
" Denite {{{
" Change file_rec command.
call denite#custom#var('file_rec', 'command',
\ ['ag', '--follow', '--nocolor', '--nogroup', '--ignore=*.pyc', '-g', ''])
" Change mappings.
call denite#custom#map(
\ 'insert',
\ 'K',
\ '<denite:move_to_next_line>',
\ 'noremap'
\)
call denite#custom#map(
\ 'insert',
\ 'L',
\ '<denite:move_to_previous_line>',
\ 'noremap'
\)
" Change sorters.
call denite#custom#source(
\ 'file_rec', 'sorters', ['sorter_sublime'])
" Change default prompt
call denite#custom#option('default', 'prompt', '➤ ')
" " Change ignore_globs
" call denite#custom#filter('matcher_ignore_globs', 'ignore_globs',
" \ [ '.git/', '.ropeproject/', '__pycache__/*', '*.pyc',
" \ 'venv/', 'images/', '*.min.*', 'img/', 'fonts/', '*.png'])
nnoremap <space>v :Denite file_rec -default-action=vsplit<cr>
nnoremap <space>s :Denite file_rec -default-action=split<cr>
nnoremap <space>e :Denite file_rec -winheight=10 <cr>
nnoremap <space>m :Denite file_mru -winheight=10 -vertical-preview -auto-preview <cr>
nnoremap <space>l :Denite line -auto-preview<cr>
" }}}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment