"====================================================================== " " init_leaderf.vim - " " Created by skywind on 2020/03/01 " Last Modified: 2020/03/01 04:43:07 " "====================================================================== "---------------------------------------------------------------------- " keymap "---------------------------------------------------------------------- let g:Lf_ShortcutF = '' let g:Lf_ShortcutB = '' let g:Lf_MruMaxFiles = 2048 let g:Lf_StlSeparator = { 'left': '', 'right': '', 'font': '' } " let g:Lf_PreviewHorizontalPosition = 'center' let g:Lf_PopupPreviewPosition='bottom' let g:Lf_PreviewInPopup = 0 " let g:Lf_QuickSelect = 1 let g:Lf_QuickSelectAction = 't' let g:Lf_GtagsAutoUpdate = 0 noremap :Leaderf --nowrap tasks inoremap :Leaderf --nowrap tasks if has('gui_running') " noremap :Leaderf --nowrap tasks " inoremap :Leaderf --nowrap tasks endif "---------------------------------------------------------------------- " LeaderF "---------------------------------------------------------------------- let g:Lf_RootMarkers = ['.project', '.root', '.svn', '.git'] let g:Lf_WorkingDirectoryMode = 'Ac' let g:Lf_WindowHeight = 0.30 let g:Lf_PopupWidth = 0.75 let g:Lf_CacheDirectory = expand('~/.vim/cache') let g:Lf_ShowRelativePath = 1 let g:Lf_HideHelp = 1 let g:Lf_NoChdir = 1 let g:Lf_WildIgnore = { \ 'dir': ['.svn','.git','.hg'], \ 'file': ['*.sw?','~$*','*.bak','*.exe','*.o','*.so','*.py[co]'] \ } let g:Lf_MruFileExclude = ['*.so', '*.exe', '*.py[co]', '*.sw?', '~$*', '*.bak', '*.tmp', '*.dll'] let g:Lf_MruMaxFiles = 2048 let g:Lf_StlColorscheme = 'powerline' let g:Lf_PopupColorscheme = 'default' let g:Lf_PopupColorscheme = 'gruvbox_default' let g:Lf_ShortcutF = '' let g:Lf_ShortcutB = '' let g:Lf_StlSeparator = { 'left': '', 'right': '', 'font': '' } let g:Lf_PreviewResult = {'Function':0, 'BufTag':0} let g:Lf_MruEnableFrecency = 1 let g:Lf_NormalMap = { \ "File": [["", ':exec g:Lf_py "fileExplManager.quit()"']], \ "Buffer": [["", ':exec g:Lf_py "bufExplManager.quit()"']], \ "Mru": [["", ':exec g:Lf_py "mruExplManager.quit()"']], \ "Tag": [["", ':exec g:Lf_py "tagExplManager.quit()"']], \ "BufTag": [["", ':exec g:Lf_py "bufTagExplManager.quit()"']], \ "Function": [["", ':exec g:Lf_py "functionExplManager.quit()"']], \ } if (exists('*popup_create') && has('patch-8.1.2000')) || has('nvim-0.4') let g:Lf_WindowPosition = 'popup' endif let g:Lf_PreviewInPopup = 1 "---------------------------------------------------------------------- " preview "---------------------------------------------------------------------- let g:Lf_PreviewResult = { \ 'File': 0, \ 'Buffer': 0, \ 'Mru': 0, \ 'Tag': 0, \ 'BufTag': 0, \ 'Function': 0, \ 'Line': 0, \ 'Colorscheme': 0, \ 'Rg': 0, \ 'Gtags': 0, \ 'Snippet': 0, \} "---------------------------------------------------------------------- " filer "---------------------------------------------------------------------- let g:Lf_FilerShowPromptPath = 1 let g:Lf_FilerInsertMap = { '': 'open_current', '': 'open_current', \ '': 'open_parent_or_backspace', '': 'up', '': 'down'} let g:Lf_FilerNormalMap = {'i': 'switch_insert_mode', '': 'quit', \ '~': 'goto_root_marker_dir', 'M': 'mkdir', 'T': 'create_file' } " let g:Lf_FilerOnlyIconHighlight = 1 "---------------------------------------------------------------------- " ctags options "---------------------------------------------------------------------- let g:Lf_CtagsFuncOpts = { \ "dosini": "--iniconf-kinds=s --language-force=iniconf", \ "taskini": "--iniconf-kinds=s --language-force=iniconf", \ } "---------------------------------------------------------------------- " keymap "---------------------------------------------------------------------- if get(g:, 'lf_disable_normal_map', 0) == 0 nnoremap ff :Leaderf file nnoremap fe :Leaderf filer nnoremap fb :Leaderf buffer nnoremap fm :Leaderf mru nnoremap fg :Leaderf gtags nnoremap fr :Leaderf rg " nnoremap fw :Leaderf window nnoremap fn :Leaderf function nnoremap ft :Leaderf tag nnoremap fu :Leaderf bufTag nnoremap fs :Leaderf self nnoremap fc :Leaderf colorscheme nnoremap fy :Leaderf cmdHistory " nnoremap fh :Leaderf help nnoremap fj :Leaderf jumps nnoremap fp :Leaderf snippet nnoremap fq :Leaderf quickfix nnoremap fa :Leaderf tasks " filer nnoremap fd :exec 'Leaderf filer ' . shellescape(expand('%:p:h')) " basic keymaps noremap :cclose:Leaderf --nowrap mru --regexMode noremap :cclose:Leaderf! --nowrap function noremap :cclose:Leaderf! --nowrap buftag noremap :cclose:Leaderf! --nowrap buffer noremap :cclose:Leaderf --nowrap tag endif if get(g:, 'lf_disable_snippet_map', 0) == 0 inoremap :Leaderf snippet endif