[[plugins]]
repo = 'https://github.com/delphinus/vim-auto-cursorline'
hook_add = '''
let g:auto_cursorline_wait_ms = 4000
'''
[plugins.ftplugin]
qf = '''
let b:auto_cursorline_disabled = v:true
'''
molder = '''
let b:auto_cursorline_disabled = v:true
'''
ddu-ff = '''
let b:auto_cursorline_disabled = v:true
'''
ddu-ff-filter = '''
let b:auto_cursorline_disabled = v:true
'''
fern = '''
let b:auto_cursorline_disabled = v:true
'''

[[plugins]]
repo = 'https://github.com/itchyny/vim-highlighturl'

[[plugins]]
repo = 'https://github.com/itchyny/vim-parenmatch'

[[plugins]]
repo = 'https://github.com/lambdalisue/vim-guise'
depends = ['denops.vim']
hook_add = '''
let g:guise_edit_opener = 'split'
'''

[[plugins]]
repo = 'https://github.com/lambdalisue/vim-mr'
# from https://github.com/kuuote/dotvim/commit/eef000e6
on_event = ['BufNewFile', 'BufReadPre', 'BufWritePre']
hook_add = '''
let s:predicates = [
      \ { fname -> fname !~# '/.git/COMMIT_EDITMSG$' },
      \ { fname -> fname !~# '\v/doc/.+\.%(txt|jax)$' },
      \ ]
let g:mr#mru#predicates = s:predicates
let g:mr#mrw#predicates = s:predicates

function! s:mr_clean(kind = 'mru') abort
  let s:kind = a:kind
  eval g:mr#{a:kind}#predicates->reduce({ acc, Pred ->
        \ acc->extend(mr#{s:kind}#list()->copy()->filter({ -> !Pred(v:val) }))
        \ }, [])
        \ ->foreach({ -> mr#{s:kind}#delete(v:val) })
endfunction
function! s:mr_complete(...)
  return ['mru', 'mrw', 'mrr', 'mrd']->join("\n")
endfunction
command! -nargs=? -complete=custom,s:mr_complete -bar MrClean call s:mr_clean(<f-args>)
'''

[[plugins]]
repo = 'https://github.com/mattn/vim-molder'
# from https://github.com/kuuote/dotvim/commit/09151c52
lazy = true
hook_add = '''
function! s:molder_init() abort
  if isdirectory(expand('%:p'))
    call dpp#source('vim-molder')
    call molder#init()
    autocmd! vimrc_molder
  endif
endfunction
augroup vimrc_molder
  autocmd!
  autocmd BufEnter * call s:molder_init()
augroup END
'''
[plugins.ftplugin]
molder = '''
setlocal nolist nospell
nnoremap <buffer> <C-l> <Plug>(molder-reload)<Cmd>set nohlsearch<CR>
nnoremap <buffer> q <C-w>q
nnoremap <buffer> <2-LeftMouse> <Plug>(molder-open)
nnoremap <buffer> <CR> <Plug>(molder-open)
nnoremap <buffer><expr> R printf('<Cmd>edit %s<CR>',
      \ systemlist('git rev-parse --show-superproject-working-tree --show-toplevel')[0])
nnoremap <buffer><expr> . $'<Cmd>edit {getcwd()}<CR>'
nnoremap <buffer><expr> j line('.') == line('$') ? 'gg' : 'j'
nnoremap <buffer><expr> k line('.') == 1         ? 'G'  : 'k'
'''

[[plugins]]
repo = 'https://github.com/mattn/vim-molder-operations'
[plugins.ftplugin]
molder = '''
nnoremap <silent><buffer> dd <Plug>(molder-operations-delete)
nnoremap <silent><buffer> r  <Plug>(molder-operations-rename)
'''

[[plugins]]
repo = 'https://github.com/rafamadriz/friendly-snippets'

[[plugins]]
repo = 'https://github.com/roxma/vim-tmux-clipboard'
if = '!has("gui_running")'

[[plugins]]
# repo = 'https://github.com/vim-denops/denops-shared-server.vim'
repo = 'https://github.com/4513ECHO/denops-shared-server.vim'
rev = 'sync-environment'
depends = ['denops.vim']
hook_add = '''
function! s:dss(action) abort
  call denops_shared_server#{a:action}()
endfunction
function! s:dss_complete(...) abort
  return ['install', 'uninstall', 'restart']->join("\n")
endfunction
command! -nargs=1 -complete=custom,s:dss_complete -bar DenopsSharedServer call s:dss(<f-args>)
'''

[[plugins]]
repo = 'https://github.com/vim-denops/denops-startup-recorder.vim'

[[plugins]]
repo = 'https://github.com/vim-jp/vimdoc-ja'