diff options
Diffstat (limited to 'modules')
-rw-r--r-- | modules/airline.vim | 12 | ||||
-rw-r--r-- | modules/ale.vim | 14 | ||||
-rw-r--r-- | modules/coc.vim | 116 | ||||
-rw-r--r-- | modules/colorizer.vim | 2 | ||||
-rw-r--r-- | modules/echodoc.vim | 1 | ||||
-rw-r--r-- | modules/emmet.vim | 4 | ||||
-rw-r--r-- | modules/fzf.vim | 63 | ||||
-rw-r--r-- | modules/general.vim | 117 | ||||
-rw-r--r-- | modules/goyo-limelight.vim | 63 | ||||
-rw-r--r-- | modules/gutentags_plus.vim | 24 | ||||
-rw-r--r-- | modules/markdowm_preview.vim | 83 | ||||
-rw-r--r-- | modules/nerdtree.vim | 30 | ||||
-rw-r--r-- | modules/polyglot.vim | 4 | ||||
-rw-r--r-- | modules/pydocstring.vim | 2 | ||||
-rw-r--r-- | modules/rainbow.vim | 23 | ||||
-rw-r--r-- | modules/ranger.vim | 2 | ||||
-rw-r--r-- | modules/relativenums.vim | 12 | ||||
-rw-r--r-- | modules/sneak.vim | 1 | ||||
-rw-r--r-- | modules/startify.vim | 16 | ||||
-rw-r--r-- | modules/terminal.vim | 25 | ||||
-rw-r--r-- | modules/theme.vim | 40 | ||||
-rw-r--r-- | modules/vim-which-key.vim | 107 | ||||
-rw-r--r-- | modules/vim_wiki.vim | 39 |
23 files changed, 0 insertions, 800 deletions
diff --git a/modules/airline.vim b/modules/airline.vim deleted file mode 100644 index 84e866c5..00000000 --- a/modules/airline.vim +++ /dev/null @@ -1,12 +0,0 @@ -" enable tabline -let g:airline#extensions#tabline#enabled = 1 -" enable powerline fonts -let g:airline_powerline_fonts = 1 -let g:airline_left_sep = '' -let g:airline_right_sep = '' -" Switch to your current theme -let g:airline_theme = 'onedark' -" Always show tabs -set showtabline=2 -" We don't need to see things like -- INSERT -- anymore -set noshowmode diff --git a/modules/ale.vim b/modules/ale.vim deleted file mode 100644 index e7c2a14c..00000000 --- a/modules/ale.vim +++ /dev/null @@ -1,14 +0,0 @@ -"Enable ale linters" -let g:ale_linters = { - \ 'cpp' : ['gcc'], - \ 'c' : ['gcc'], - \ 'vim' : ['~/.miniconda/envs/neovim/bin/vint'], - \ 'python': [], - \ 'javascript': [] - \} - "\ 'python': ['pyls','pydocstyle', 'pycodestyle'], - -let g:ale_fixers = { -\ '*': ['remove_trailing_lines', 'trim_whitespace'], -\ 'python': ['yapf'], -\} diff --git a/modules/coc.vim b/modules/coc.vim deleted file mode 100644 index 54451731..00000000 --- a/modules/coc.vim +++ /dev/null @@ -1,116 +0,0 @@ -" TextEdit might fail if hidden is not set. -set hidden - -" Some servers have issues with backup files, see #649. -set nobackup -set nowritebackup - -" Give more space for displaying messages. -set cmdheight=2 - -" Having longer updatetime (default is 4000 ms = 4 s) leads to noticeable -" delays and poor user experience. -set updatetime=300 - -" Don't pass messages to |ins-completion-menu|. -set shortmess+=c - -" Always show the signcolumn, otherwise it would shift the text each time -" diagnostics appear/become resolved. -set signcolumn=yes - -"better nav for omnicomplete -inoremap <expr> <c-j> ("\<C-n>") -inoremap <expr> <c-k> ("\<C-p>") - -" Use tab for trigger completion with characters ahead and navigate. -" NOTE: Use command ':verbose imap <tab>' to make sure tab is not mapped by -" other plugin before putting this into your config. -"inoremap <silent><expr> <TAB> - "\ pumvisible() ? "\<C-n>" : - "\ <SID>check_back_space() ? "\<TAB>" : - "\ coc#refresh() -"inoremap <expr><S-TAB> pumvisible() ? "\<C-p>" : "\<C-h>" - -function! s:check_back_space() abort - let col = col('.') - 1 - return !col || getline('.')[col - 1] =~# '\s' -endfunction - -" Use <c-space> to trigger completion. -inoremap <silent><expr> <c-space> coc#refresh() - -" Use <cr> to confirm completion, `<C-g>u` means break undo chain at current -" position. Coc only does snippet and additional edit on confirm. -if has('patch8.1.1068') - " Use `complete_info` if your (Neo)Vim version supports it. - inoremap <expr> <cr> complete_info()["selected"] != "-1" ? "\<C-y>" : "\<C-g>u\<CR>" -else - imap <expr> <cr> pumvisible() ? "\<C-y>" : "\<C-g>u\<CR>" -endif - -" Use `[g` and `]g` to navigate diagnostics -nmap <silent> [g <Plug>(coc-diagnostic-prev) -nmap <silent> ]g <Plug>(coc-diagnostic-next) - -" GoTo code navigation. -nmap <silent> gd <Plug>(coc-definition) -nmap <silent> gy <Plug>(coc-type-definition) -nmap <silent> gi <Plug>(coc-implementation) -nmap <silent> gr <Plug>(coc-references) - -" Use K to show documentation in preview window. -nnoremap <silent> K :call <SID>show_documentation()<CR> - -function! s:show_documentation() - if (index(['vim','help'], &filetype) >= 0) - execute 'h '.expand('<cword>') - else - call CocAction('doHover') - endif -endfunction - -" Highlight the symbol and its references when holding the cursor. -autocmd CursorHold * silent call CocActionAsync('highlight') - -augroup mygroup - autocmd! - " Setup formatexpr specified filetype(s). - autocmd FileType typescript,json setl formatexpr=CocAction('formatSelected') - " Update signature help on jump placeholder. - autocmd User CocJumpPlaceholder call CocActionAsync('showSignatureHelp') -augroup end - -" Add `:Format` command to format current buffer. -command! -nargs=0 Format :call CocAction('format') - -" Add `:Fold` command to fold current buffer. -command! -nargs=? Fold :call CocAction('fold', <f-args>) - -" Add `:OR` command for organize imports of the current buffer. -command! -nargs=0 OR :call CocAction('runCommand', 'editor.action.organizeImport') - -" Add (Neo)Vim's native statusline support. -" NOTE: Please see `:h coc-status` for integrations with external plugins that -" provide custom statusline: lightline.vim, vim-airline. -set statusline^=%{coc#status()}%{get(b:,'coc_current_function','')} - -" Mappings using CoCList: -" Show all diagnostics. -nnoremap <silent> <space>a :<C-u>CocList diagnostics<cr> -" Manage extensions. -nnoremap <silent> <space>x :<C-u>CocList extensions<cr> -" Show commands. -nnoremap <silent> <space>c :<C-u>CocList commands<cr> -" Find symbol of current document. -nnoremap <silent> <space>o :<C-u>CocList outline<cr> -" Search workspace symbols. -nnoremap <silent> <space>s :<C-u>CocList -I symbols<cr> -" Do default action for next item. -nnoremap <silent> <space>j :<C-u>CocNext<CR> -" Do default action for previous item. -nnoremap <silent> <space>k :<C-u>CocPrev<CR> -" Resume latest coc list. -nnoremap <silent> <space>p :<C-u>CocListResume<CR> - -nmap <silent> <C-_> <Plug>(pydocstring) diff --git a/modules/colorizer.vim b/modules/colorizer.vim deleted file mode 100644 index 176d78ca..00000000 --- a/modules/colorizer.vim +++ /dev/null @@ -1,2 +0,0 @@ -lua require'colorizer'.setup() - diff --git a/modules/echodoc.vim b/modules/echodoc.vim deleted file mode 100644 index e2ba0c4b..00000000 --- a/modules/echodoc.vim +++ /dev/null @@ -1 +0,0 @@ -let g:echodoc#enable_at_startup=1 diff --git a/modules/emmet.vim b/modules/emmet.vim deleted file mode 100644 index f12fdf95..00000000 --- a/modules/emmet.vim +++ /dev/null @@ -1,4 +0,0 @@ -" You will need to press , after this key -let g:user_emmet_leader_key=',' -let g:user_emmet_mode='n' "only enable normal mode functions. - diff --git a/modules/fzf.vim b/modules/fzf.vim deleted file mode 100644 index 4466a32f..00000000 --- a/modules/fzf.vim +++ /dev/null @@ -1,63 +0,0 @@ -" This is the default extra key bindings -let g:fzf_action = { - \ 'ctrl-t': 'tab split', - \ 'ctrl-x': 'split', - \ 'ctrl-v': 'vsplit' } - -" An action can be a reference to a function that processes selected lines -function! s:build_quickfix_list(lines) - call setqflist(map(copy(a:lines), '{ "filename": v:val }')) - copen - cc -endfunction - -let g:fzf_action = { - \ 'ctrl-q': function('s:build_quickfix_list'), - \ 'ctrl-t': 'tab split', - \ 'ctrl-x': 'split', - \ 'ctrl-v': 'vsplit' } - -" Default fzf layout -" - down / up / left / right -let g:fzf_layout = { 'down': '~40%' } - -" You can set up fzf window using a Vim command (Neovim or latest Vim 8 required) -let g:fzf_layout = { 'window': 'enew' } -let g:fzf_layout = { 'window': '-tabnew' } -let g:fzf_layout = { 'window': '10new' } - -" Customize fzf colors to match your color scheme -" - fzf#wrap translates this to a set of `--color` options -let g:fzf_colors = -\ { 'fg': ['fg', 'Normal'], - \ 'bg': ['bg', 'Normal'], - \ 'hl': ['fg', 'Comment'], - \ 'fg+': ['fg', 'CursorLine', 'CursorColumn', 'Normal'], - \ 'bg+': ['bg', 'CursorLine', 'CursorColumn'], - \ 'hl+': ['fg', 'Statement'], - \ 'info': ['fg', 'PreProc'], - \ 'border': ['fg', 'Ignore'], - \ 'prompt': ['fg', 'Conditional'], - \ 'pointer': ['fg', 'Exception'], - \ 'marker': ['fg', 'Keyword'], - \ 'spinner': ['fg', 'Label'], - \ 'header': ['fg', 'Comment'] } - -" Enable per-command history -" - History files will be stored in the specified directory -" - When set, CTRL-N and CTRL-P will be bound to 'next-history' and -" 'previous-history' instead of 'down' and 'up'. -"let g:fzf_history_dir = '~/.local/share/fzf-history' - -if has('nvim') && !exists('g:fzf_layout') - autocmd! FileType fzf - autocmd FileType fzf set laststatus=0 noshowmode noruler - \| autocmd BufLeave <buffer> set laststatus=2 showmode ruler -endif - -if has("nvim") - au TermOpen * tnoremap <Esc> <c-\><c-n> - au FileType fzf tunmap <Esc> -endif - -nnoremap <C-p> :FZF<CR> diff --git a/modules/general.vim b/modules/general.vim deleted file mode 100644 index 178e19f3..00000000 --- a/modules/general.vim +++ /dev/null @@ -1,117 +0,0 @@ -" Be IMproved -if &compatible - set nocompatible -endif - -" set leader key -let g:mapleader = "\<Space>" -" set local leader key -let g:maplocalleader = ',' - -syntax enable " Enables syntax highlighing -"set hidden " Required for specific actions that require multiple buffers -set nowrap " display long lines as just one line -set encoding=utf-8 " The encoding displayed -set pumheight=10 " Makes popup menu smaller -set fileencoding=utf-8 " The encoding written to file -set ruler " show the cursor position all the time -set cmdheight=2 " always keep this at 2" -set iskeyword+=- " treat dash separated words as a word text object" -set mouse=a " Enable your mouse -set splitbelow " Horizontal splits will automatically be below -set splitright " Vertical splits will automatically be to the right -set t_Co=256 " Support 256 colors -"set autochdir " Your working directory will always be the same as your working directory -set conceallevel=0 " So that I can see `` in markdown files -set tabstop=2 " Insert 2 spaces for a tab -set shiftwidth=2 " Change the number of space characters inserted for indentation -set smarttab " Makes tabbing smarter will realize you have 2 vs 4 -set expandtab " Converts tabs to spaces -set smartindent " Makes indenting smart -set autoindent " Good auto indent -set laststatus=0 " Always display the status line -set number " Line numbers -set cursorline " Enable highlighting of the current line -set background=dark " tell vim what the background color looks like - -let g:elite_mode=1 " Disable arrows" -filetype plugin indent on " Gives vim abilty to recognize filetypes - -" Disable arrow movement, resize splits instead. -if get(g:, 'elite_mode') - nnoremap <Up> :resize -2<CR> - nnoremap <Down> :resize +2<CR> - nnoremap <Left> :vertical resize -2<CR> - nnoremap <Right> :vertical resize +2<CR> -endif - -" Alternate way to save -nnoremap <C-s> :w<CR> -" Alternate way to quit -nnoremap <C-Q> :wq!<CR> -" Use control-c instead of escape -nnoremap <C-c> <Esc> -" <TAB>: completion. -inoremap <expr><TAB> pumvisible() ? "\<C-n>" : "\<TAB>" -" Open terminal with F1 -nnoremap <silent> <F1> :10split term://bash<CR> -nnoremap <silent> <F2> :bdelete! term://*<return> - -inoremap K <c-d> -nnoremap J <c-u> - -nnoremap <C-h> <C-w>h -nnoremap <C-j> <C-w>j -nnoremap <C-k> <C-w>k -nnoremap <C-l> <C-w>l -" Remap terminal switch -tnoremap <C-[> <C-\><C-n> -tnoremap <C-c><Esc> <Esc> -tnoremap <C-h> <C-\><C-n><C-w>h -tnoremap <C-j> <C-\><C-n><C-w>j -tnoremap <C-k> <C-\><C-n><C-w>k -tnoremap <C-l> <C-\><C-n><C-w>l - -nnoremap <M-h> <C-w>h -nnoremap <M-j> <C-w>j -nnoremap <M-k> <C-w>k -nnoremap <M-l> <C-w>l - -" I think this does something on mac but I might be full of shit -nnoremap <D-h> <C-w>h -nnoremap <D-j> <C-w>j -nnoremap <D-k> <C-w>k -nnoremap <D-l> <C-w>l - -" I hate escape more than anything else -inoremap jk <Esc> -inoremap kj <Esc> -" This is how much I hate it -"inoremap <esc> <nop> - -" Easy CAPS -inoremap <c-u> <ESC>viwUi -nnoremap <c-u> viwU<Esc> - - -" TAB in general mode will move to text buffer -nnoremap <C-TAB> :VimwikiNextLink<CR> -" SHIFT-TAB will go back -nnoremap <C-S-TAB> :VimwikiPrevLink<CR> - - -"nmap <Leader>wn <Plug>VimwikiNextLink -"nmap <Leader>wp <Plug>VimwikiPrevLink -" TAB in general mode will move to text buffer -nnoremap <TAB> :bnext<CR> -" SHIFT-TAB will go back -nnoremap <S-TAB> :bprevious<CR> - -" Copy paste between vim and everything else -set clipboard=unnamedplus - -" hold when tabbing -vnoremap < <gv -vnoremap > >gv - -cmap w!! w !sudo tee % diff --git a/modules/goyo-limelight.vim b/modules/goyo-limelight.vim deleted file mode 100644 index ab3f3441..00000000 --- a/modules/goyo-limelight.vim +++ /dev/null @@ -1,63 +0,0 @@ - -"Make window a little bigger" -" -let g:goyo_width=100 -let g:goy_height=95 -" -" -" Disable Deoplete " - -function! s:goyo_enter() - - "call deoplete#custom#option('auto_complete', v:false) - "set spell spelllang=en_us - set wrap - set conceallevel=0 - set tw=100 - set noshowcmd - set scrolloff=999 -"" set background=light -"" colorscheme flattened_light - "Limelight - " ... -endfunction - -function! s:goyo_leave() - - "call deoplete#custom#option('auto_complete', v:true) - "set nospell - set wrap! - set showcmd - set scrolloff=5 -"" set background=dark -"" colorscheme Tender - "Limelight! - " ... -endfunction - -autocmd! User GoyoEnter nested call <SID>goyo_enter() -autocmd! User GoyoLeave nested call <SID>goyo_leave() - -" Color name (:help cterm-colors) or ANSI code -let g:limelight_conceal_ctermfg = 'gray' -let g:limelight_conceal_ctermfg = 240 - -" Color name (:help gui-colors) or RGB color -let g:limelight_conceal_guifg = 'DarkGray' -let g:limelight_conceal_guifg = '#777777' - -" Default: 0.5 -let g:limelight_default_coefficient = 0.7 - -" Number of preceding/following paragraphs to include (default: 0) -let g:limelight_paragraph_span = 0 - -" Beginning/end of paragraph -" When there's no empty line between the paragraphs -" and each paragraph starts with indentation -let g:limelight_bop = '^\s' -let g:limelight_eop = '\ze\n^\s' - -" Highlighting priority (default: 10) -" Set it to -1 not to overrule hlsearch -let g:limelight_priority = -1 diff --git a/modules/gutentags_plus.vim b/modules/gutentags_plus.vim deleted file mode 100644 index 370cf7f6..00000000 --- a/modules/gutentags_plus.vim +++ /dev/null @@ -1,24 +0,0 @@ -" enable gtags module -let g:gutentags_modules = ['ctags', 'gtags_cscope'] - -" config project root markers. -let g:gutentags_project_root = ['.root', '.git'] - -" generate datebases in my cache directory, prevent gtags files polluting my project -let g:gutentags_cache_dir = expand('~/.cache/tags') - -" change focus to quickfix window after search (optional). -""let g:gutentags_plus_switch = 1 - -" This will ignore everything in .gitignore" -let g:gutentags_file_list_command = 'rg --files' - -"Install ripgrep" -"Install ctags" -".notags will ignore everything" - -" I think this is built in but it's nice to know that if yo -" have ripgrep ctags will ignore everyhting in your .gitignore -if executable('rg') - let g:gutentags_file_list_command = 'rg --files' -endif diff --git a/modules/markdowm_preview.vim b/modules/markdowm_preview.vim deleted file mode 100644 index 0a87f897..00000000 --- a/modules/markdowm_preview.vim +++ /dev/null @@ -1,83 +0,0 @@ -" set to 1, nvim will open the preview window after entering the markdown buffer -" default: 0 -let g:mkdp_auto_start = 0 - -" set to 1, the nvim will auto close current preview window when change -" from markdown buffer to another buffer -" default: 1 -let g:mkdp_auto_close = 0 - -" set to 1, the vim will refresh markdown when save the buffer or -" leave from insert mode, default 0 is auto refresh markdown as you edit or -" move the cursor -" default: 0 -let g:mkdp_refresh_slow = 0 - -" set to 1, the MarkdownPreview command can be use for all files, -" by default it can be use in markdown file -" default: 0 -let g:mkdp_command_for_global = 0 - -" set to 1, preview server available to others in your network -" by default, the server listens on localhost (127.0.0.1) -" default: 0 -let g:mkdp_open_to_the_world = 1 - -" use custom IP to open preview page -" useful when you work in remote vim and preview on local browser -" more detail see: https://github.com/iamcco/markdown-preview.nvim/pull/9 -" default empty -let g:mkdp_open_ip = '' - -" specify browser to open preview page -" default: '' -let g:mkdp_browser = '' - -" set to 1, echo preview page url in command line when open preview page -" default is 0 -let g:mkdp_echo_preview_url = 0 - -" a custom vim function name to open preview page -" this function will receive url as param -" default is empty -let g:mkdp_browserfunc = '' - -" options for markdown render -" mkit: markdown-it options for render -" katex: katex options for math -" uml: markdown-it-plantuml options -" maid: mermaid options -" disable_sync_scroll: if disable sync scroll, default 0 -" sync_scroll_type: 'middle', 'top' or 'relative', default value is 'middle' -" middle: mean the cursor position alway show at the middle of the preview page -" top: mean the vim top viewport alway show at the top of the preview page -" relative: mean the cursor position alway show at the relative positon of the preview page -" hide_yaml_meta: if hide yaml metadata, default is 1 -" sequence_diagrams: js-sequence-diagrams options -let g:mkdp_preview_options = { - \ 'mkit': {}, - \ 'katex': {}, - \ 'uml': {}, - \ 'maid': {}, - \ 'disable_sync_scroll': 0, - \ 'sync_scroll_type': 'middle', - \ 'hide_yaml_meta': 1, - \ 'sequence_diagrams': {}, - \ 'flowchart_diagrams': {} - \ } - -" use a custom markdown style must be absolute path -" like '/Users/username/markdown.css' or expand('~/markdown.css') -let g:mkdp_markdown_css = '' - -" use a custom highlight style must absolute path -" like '/Users/username/highlight.css' or expand('~/highlight.css') -let g:mkdp_highlight_css = '' - -" use a custom port to start server or random for empty -let g:mkdp_port = '' - -" preview page title -" ${name} will be replace with the file name -let g:mkdp_page_title = '「${name}」' - diff --git a/modules/nerdtree.vim b/modules/nerdtree.vim deleted file mode 100644 index 54f4a655..00000000 --- a/modules/nerdtree.vim +++ /dev/null @@ -1,30 +0,0 @@ -let NERDTreeShowHidden = 1 " show hidden files -let g:NERDCreateDefaultMappings = 0 -" automatically close when you open a file" -"let NERDTreeQuitOnOpen = 1 - -" let nvim close when nerdtree is last thing" -autocmd bufenter * if (winnr("$") == 1 && exists("b:NERDTree") && b:NERDTree.isTabTree()) | q | endif - - -" nerdtree will delete buffer of file " - - let NERDTreeAutoDeleteBuffer = 1 - -" if you need help press ? while in nerdtree " -""let NERDTreeMinimalUI = 1 -let NERDTreeDirArrows = 1 - - -"This depends on vim-nerdtree-syntax-highlight" -let g:NERDTreeFileExtensionHighlightFullName = 1 -let g:NERDTreeExactMatchHighlightFullName = 1 -let g:NERDTreePatternMatchHighlightFullName = 1 - -let g:NERDTreeHighlightFolders = 1 " enables folder icon highlighting using exact match -let g:NERDTreeHighlightFoldersFullName = 1 " highlights the folder name -" Original coloring -highlight! link NERDTreeFlags NERDTreeDir -" Get rid of help thing at the top -"let NERDTreeMinimalUI=1 - diff --git a/modules/polyglot.vim b/modules/polyglot.vim deleted file mode 100644 index 08c5d72c..00000000 --- a/modules/polyglot.vim +++ /dev/null @@ -1,4 +0,0 @@ -aug i3config_ft_detection - au! - au BufNewFile,BufRead ~/.config/i3/config set filetype=i3config -aug end diff --git a/modules/pydocstring.vim b/modules/pydocstring.vim deleted file mode 100644 index 34ce0e64..00000000 --- a/modules/pydocstring.vim +++ /dev/null @@ -1,2 +0,0 @@ -nmap <silent> <leader>doc <Plug>(pydocstring) - diff --git a/modules/rainbow.vim b/modules/rainbow.vim deleted file mode 100644 index 3403f902..00000000 --- a/modules/rainbow.vim +++ /dev/null @@ -1,23 +0,0 @@ -let g:rainbow_active = 1 "0 if you want to enable it later via :RainbowToggle -let g:rainbow_conf = { - \ 'guifgs': ['royalblue3', 'darkorange3', 'seagreen3', 'firebrick'], - \ 'ctermfgs': ['lightblue', 'lightyellow', 'lightcyan', 'lightmagenta'], - \ 'operators': '_,_', - \ 'parentheses': ['start=/(/ end=/)/ fold', 'start=/\[/ end=/\]/ fold', 'start=/{/ end=/}/ fold'], - \ 'separately': { - \ '*': {}, - \ 'tex': { - \ 'parentheses': ['start=/(/ end=/)/', 'start=/\[/ end=/\]/'], - \ }, - \ 'lisp': { - \ 'guifgs': ['royalblue3', 'darkorange3', 'seagreen3', 'firebrick', 'darkorchid3'], - \ }, - \ 'vim': { - \ 'parentheses': ['start=/(/ end=/)/', 'start=/\[/ end=/\]/', 'start=/{/ end=/}/ fold', 'start=/(/ end=/)/ containedin=vimFuncBody', 'start=/\[/ end=/\]/ containedin=vimFuncBody', 'start=/{/ end=/}/ fold containedin=vimFuncBody'], - \ }, - \ 'html': { - \ 'parentheses': ['start=/\v\<((area|base|br|col|embed|hr|img|input|keygen|link|menuitem|meta|param|source|track|wbr)[ >])@!\z([-_:a-zA-Z0-9]+)(\s+[-_:a-zA-Z0-9]+(\=("[^"]*"|'."'".'[^'."'".']*'."'".'|[^ '."'".'"><=`]*))?)*\>/ end=#</\z1># fold'], - \ }, - \ 'css': 0, - \ } - \} diff --git a/modules/ranger.vim b/modules/ranger.vim deleted file mode 100644 index 72b41c89..00000000 --- a/modules/ranger.vim +++ /dev/null @@ -1,2 +0,0 @@ -let g:NERDTreeHijackNetrw = 0 " add this line if you use NERDTree -let g:ranger_replace_netrw = 1 " open ranger when vim open a directory diff --git a/modules/relativenums.vim b/modules/relativenums.vim deleted file mode 100644 index 106560e0..00000000 --- a/modules/relativenums.vim +++ /dev/null @@ -1,12 +0,0 @@ -set relativenumber -function! NumberToggle() - if(&relativenumber == 1) - set number - set norelativenumber - else - set number - set relativenumber - endif -endfunc - -nnoremap <leader>rn :call NumberToggle()<cr> diff --git a/modules/sneak.vim b/modules/sneak.vim deleted file mode 100644 index b3e8f561..00000000 --- a/modules/sneak.vim +++ /dev/null @@ -1 +0,0 @@ -let g:sneak#label = 1 diff --git a/modules/startify.vim b/modules/startify.vim deleted file mode 100644 index 6f12ecc4..00000000 --- a/modules/startify.vim +++ /dev/null @@ -1,16 +0,0 @@ - -"let g:startify_custom_header = [ -"\ ' __ _________ __ ____ ____.__ ', -"\ ' / / / _____/__________ ____ ____ \ \ \ \ / /|__| _____ ', -"\ '/ / \_____ \\____ \__ \ _/ ___\/ __ \ \ \ \ Y / | |/ \ ', -"\ '\ \ / \ |_> > __ \\ \__\ ___/ / / \ / | | Y Y \ ', -"\ ' \_\ /_______ / __(____ /\___ >___ > /_/ \___/ |__|__|_| / ', -"\ ' \/|__| \/ \/ \/ \/ '] - - -let g:startify_custom_header = [ - \ ' _ __ _ ', - \ ' / | / /__ ____ _ __(_)___ ___ ', - \ ' / |/ / _ \/ __ \ | / / / __ `__ \', - \ ' / /| / __/ /_/ / |/ / / / / / / /', - \ ' /_/ |_/\___/\____/|___/_/_/ /_/ /_/ '] diff --git a/modules/terminal.vim b/modules/terminal.vim deleted file mode 100644 index 5dfe28c3..00000000 --- a/modules/terminal.vim +++ /dev/null @@ -1,25 +0,0 @@ -" I am experimenting with different ways to use the terminal in nvim " -" So far I hate all my options - -let s:term_buf = 0 -let s:term_win = 0 - -function! Term_toggle(height) - if win_gotoid(s:term_win) - hide - else - botright new - exec "resize " . a:height - try - exec "buffer " . s:term_buf - catch - call termopen($SHELL, {"detach": 0}) - let s:term_buf = bufnr("") - endtry - startinsert! - let s:term_win = win_getid() - endif -endfunction - -nnoremap <silent> <M-t> :call Term_toggle(10)<cr> -tnoremap <silent> <M-t> <C-\><C-n>:call Term_toggle(10)<cr> diff --git a/modules/theme.vim b/modules/theme.vim deleted file mode 100644 index 34a4e98b..00000000 --- a/modules/theme.vim +++ /dev/null @@ -1,40 +0,0 @@ -" Switch to whatever colorscheme you like - -" onedark.vim override: Don't set a background color when running in a terminal; -" just use the terminal's background color -" `gui` is the hex color code used in GUI mode/nvim true-color mode -" `cterm` is the color code used in 256-color mode -" `cterm16` is the color code used in 16-color mode -if (has("autocmd") && !has("gui_running")) - augroup colorset - autocmd! - let s:white = { "gui": "#ABB2BF", "cterm": "145", "cterm16" : "7" } - autocmd ColorScheme * call onedark#set_highlight("Normal", { "fg": s:white }) " `bg` will not be styled since there is no `bg` setting - augroup END -endif - -hi Comment cterm=italic -let g:onedark_hide_endofbuffer=1 -let g:onedark_terminal_italics=1 -let g:onedark_termcolors=256 - -syntax on -colorscheme onedark - - -" checks if your terminal has 24-bit color support -if (has("termguicolors")) - set termguicolors - hi LineNr ctermbg=NONE guibg=NONE -endif - -" Syntax highlighting -let g:python_highlight_all=1 - -" Change this when you know where i3 will be -aug i3config_ft_detection - au! - au BufNewFile,BufRead ~/.config/i3/config set filetype=i3config -aug end - -" TODO checkout vim-jsx diff --git a/modules/vim-which-key.vim b/modules/vim-which-key.vim deleted file mode 100644 index 1341f596..00000000 --- a/modules/vim-which-key.vim +++ /dev/null @@ -1,107 +0,0 @@ -" set which key -" -" Any keymapping that involves <leader is here> -nnoremap <silent> <leader> :WhichKey '<Space>'<CR> -let g:which_key_sep = '→' - -" By default timeoutlen is 1000 ms -set timeoutlen=100 - - -let g:which_key_map = {} -"let g:which_key_default_group_name = '' -"let g:which_key_map.f = { 'name' : '+file' } -"nnoremap <silent> <leader>fs :update<CR> -"let g:which_key_map.f.s = ['update', 'save-file'] - -" This is a funtion to open any file with <leader>(key sequence) -fun! OpenConfigFile(file) - if (&filetype ==? 'startify') - execute 'e ' . a:file - else - execute 'tabe ' . a:file - endif -endfun - -"nnoremap <silent> <leader>in :call OpenConfigFile('~/.config/nvim/init.vim')<cr> -"nnoremap <silent> <leader>bashrc :call OpenConfigFile('~/.bashrc')<cr> -"nnoremap <silent> <leader>code :call OpenConfigFile('~/Library/Application Support/Code/User/settings.json')<cr> - -nnoremap <leader>" viw<esc>a"<esc>bi"<esc>lel -let g:which_key_map['/'] = [ '<Plug>NERDCommenterToggle' , 'commenter' ] -let g:which_key_map['e'] = [ 'NERDTreeToggle' , 'file-explorer' ] -let g:which_key_map['p'] = [ 'pclose' , 'close-preview' ] -let g:which_key_map['q'] = [ 'q' , 'quit' ] -let g:which_key_map['d'] = [ 'bd' , 'delete-buffer' ] -let g:which_key_map['s'] = [ 'w' , 'save' ] -let g:which_key_map['r'] = [ 'Ranger' , 'ranger' ] -let g:which_key_map['f'] = [ 'FZF' , 'fzf' ] -let g:which_key_map['z'] = [ 'Goyo' , 'zen-mode' ] -let g:which_key_map['v'] = ['<C-W>v' , 'split-window-right'] -let g:which_key_map['h'] = ['<C-W>s' , 'split-window-below'] -let g:which_key_map['o'] = ['only' , 'close-all-other-windows'] -"let g:which_key_map[','] = ['vsplit $NVIMRC ' , 'open-init.vim'] -"let g:which_key_map['.'] = ['source $NVIMRC ' , 'source-init.vim'] -let g:which_key_map['"'] = ['viw<esc>a"<esc>bi"<esc>lel' , 'surround'] -" Surround in \"" -nnoremap <leader>" viw<esc>a"<esc>bi"<esc>lel - -let g:which_key_map.t = { - \ 'name' : '+toggle' , - \ 'e' : ['NERDTreeToggle' , 'file-explorer'] , - \ 'b' : ['TagbarToggle' , 'tagbar'] , - \ 'n' : [':set nonumber!' , 'line-numbers'] , - \ 'r' : [':set norelativenumber!' , 'rel-line-numbers'] , - \ 's' : [':let @/ = ""' , 'remove-search-highlight'] , - \ 'c' : ['ColorToggle' , 'remove-color'] , - \ 't' : [':6sp term://zsh' , 'terminal'] , - \ } - - -let g:which_key_map.l = { - \ 'name' : '+lsp' , - \ 'a' : ['<Plug>(coc-codeaction-selected)' , 'rename symbol'] , - \ 'r' : ['<Plug>(coc-rename)' , 'rename symbol'] , - \ 'f' : ['<Plug>(coc-fix-current)' , 'fix'] , - \ 'i' : ['ALEInfo' , 'info'] , - \ 'h' : ['<Plug>(ale_hover)' , 'hover'] , - \ 'R' : ['LanguageClient#textDocument_rename()' , 'rename'] , - \ 's' : ['LanguageClient#textDocument_documentSymbol()' , 'document-symbol'] , - \ 'S' : ['LanguageClient#workspace_symbol()' , 'workspace-symbol'] , - \ 'g' : { - \ 'name': '+goto', - \ 't' : ['LanguageClient#textDocument_typeDefinition()' , 'type-definition'] , - \ 'i' : ['LanguageClient#textDocument_implementation()' , 'implementation'] , - \ }, - \ 'p' : { - \ 'name': '+python', - \ 'd' : ['<Plug>(pydocstring)' , 'python-docstring'] , - \ }, - \ } - -let g:which_key_map.b = { - \ 'name' : '+buffer' , - \ '1' : ['b1' , 'buffer 1'] , - \ '2' : ['b2' , 'buffer 2'] , - \ 'd' : ['bd' , 'delete-buffer'] , - \ 'f' : ['bfirst' , 'first-buffer'] , - \ 'l' : ['blast' , 'last-buffer'] , - \ 'n' : ['bnext' , 'next-buffer'] , - \ 'p' : ['bprevious' , 'previous-buffer'] , - \ '?' : ['Buffers' , 'fzf-buffer'] , - \ 's' : ['Startify' , 'Startify'] , - \ 'g' : ['Goyo' , 'Goyo'] , - \ } - -call which_key#register('<Space>', "g:which_key_map") -nnoremap <silent> <leader> :<c-u>WhichKey '<Space>'<CR> -vnoremap <silent> <leader> :<c-u>WhichKeyVisual '<Space>'<CR> - -" Get rid of status bar when not in use -autocmd! FileType which_key -autocmd FileType which_key set laststatus=0 noshowmode noruler - \| autocmd BufLeave <buffer> set laststatus=2 showmode ruler - -""nnoremap <silent> <leader> :<c-u>WhichKey '<Space>'<CR> -""nnoremap <silent> <localleader> :<c-u>WhichKey ','<CR> -let g:which_key_use_floating_win = 0 diff --git a/modules/vim_wiki.vim b/modules/vim_wiki.vim deleted file mode 100644 index 84e5e086..00000000 --- a/modules/vim_wiki.vim +++ /dev/null @@ -1,39 +0,0 @@ -let wiki_1 = {} -let wiki_1.syntax = 'markdown' -let wiki_1.ext = '.md' -"set concealcursor=nc -let g:vimwiki_list = [{'path': '~/wiki/', - \ 'syntax': 'markdown', 'ext': '.md'}] - -" TAB in general mode will move to text buffer -"nnoremap <TAB> :bnext<CR> -" SHIFT-TAB will go back -"nnoremap <S-TAB> :bprevious<CR> - -let g:indentLine_setConceal = 0 -let g:indentLine_concealcursor = "" -set conceallevel=0 - - -"let g:vimwiki_list = [{'path': '~/wiki/', 'index': 'main'}] -"Key bindings -"Normal mode: - -"<Leader>ww -- Open default wiki index file. -"<Leader>wt -- Open default wiki index file in a new tab. -"<Leader>ws -- Select and open wiki index file. -"<Leader>wd -- Delete wiki file you are in. -"<Leader>wr -- Rename wiki file you are in. -"<Enter> -- Follow/Create wiki link -"<Shift-Enter> -- Split and follow/create wiki link -"<Ctrl-Enter> -- Vertical split and follow/create wiki link -"<Backspace> -- Go back to parent(previous) wiki link -"<Tab> -- Find next wiki link -"<Shift-Tab> -- Find previous wiki link -"For more keys, see :h vimwiki-mappings - -"Commands -":Vimwiki2HTML -- Convert current wiki link to HTML -":VimwikiAll2HTML -- Convert all your wiki links to HTML -":help vimwiki-commands -- list all commands -":help vimwiki -- General vimwiki help docs |