فهرست منبع

Add tunings from last procrastination session

Kevin 5 سال پیش
والد
کامیت
1f1b860768
3فایلهای تغییر یافته به همراه16 افزوده شده و 6 حذف شده
  1. 1 0
      gitignore_global
  2. 11 5
      nvimrc
  3. 4 1
      tmux.conf

+ 1 - 0
gitignore_global

@@ -45,3 +45,4 @@ __pycache__/
 .clang
 toolchain.cmake
 livepreview/
+.env

+ 11 - 5
nvimrc

@@ -29,14 +29,15 @@ Plug 'ap/vim-css-color'
 Plug 'mattn/emmet-vim'
 Plug 'ctrlpvim/ctrlp.vim'
 Plug 'tpope/vim-commentary'
-Plug 'pangloss/vim-javascript'
+Plug 'pangloss/vim-javascript', { 'for': 'javacript' }
 Plug 'easymotion/vim-easymotion'
 Plug 'tpope/vim-unimpaired'
 Plug 'tpope/vim-surround'
 Plug 'christoomey/vim-tmux-navigator'
 Plug 'roxma/vim-tmux-clipboard'
 Plug 'Chiel92/vim-autoformat'
-Plug 'apple/swift', { 'rtp': 'utils/vim' }
+" Plug 'apple/swift', { 'rtp': 'utils/vim', 'for': 'swift', 'frozen': 'true' }
+Plug 'keith/swift.vim'
 Plug 'https://bitbucket.org/johanneskoester/snakemake.git', {'rtp': 'misc/vim/'}
 Plug 'junegunn/vim-easy-align'
 Plug 'glench/vim-jinja2-syntax'
@@ -106,9 +107,12 @@ set expandtab " use 'tabstop' spaces instead of tab
 set colorcolumn=80 " Bar hinting for 80 chars
 set breakindent "baby, yeah!
 set mouse=a " activate mouse support
-set ignorecase " ignore case while searching
 set relativenumber  " aka :set rnu
 
+" searching
+set ignorecase " ignore case while searching
+nnoremap <C-s> :set hlsearch!<CR>
+
 " autoformatting
 let g:formatter_python = ['yapf']
 let g:formatter_yapf_style = 'pep8'
@@ -205,13 +209,15 @@ let g:vimtex_compiler_latexmk={
 
 " use deoplete
 let g:deoplete#enable_at_startup = 1
-
+" close preview window after completion or on leave https://github.com/Shougo/deoplete.nvim/issues/115
+autocmd InsertLeave,CompleteDone * if pumvisible() == 0 | pclose | endif
 " deoplete tab-complete
 inoremap <expr><tab> pumvisible() ? "\<c-n>" : "\<tab>"
-
 " deoplete clang completion
 let g:deoplete#sources#clang#clang_complete_database = '/net/nfshome/home/kheinicke/DevEnvironments/FTDevelopment/PHYS/PHYS_flavtagmaster/build.x86_64-centos7-gcc62-opt/'
 let g:deoplete#sources#clang#libclang_path = '/net/nfshome/home/kheinicke/.local/lib/libclang.so'
+" show docstring in preview window
+let g:deoplete#sources#jedi#show_docstring = 1
 
 " vimtex settings
 let g:vimtex_matchparen_enabled=0  " turn off folding to speed up things

+ 4 - 1
tmux.conf

@@ -2,6 +2,7 @@
 set -g @plugin 'tmux-plugins/tpm'
 set -g @plugin 'tmux-plugins/tmux-sensible'
 set -g @plugin 'christoomey/vim-tmux-navigator'
+set -g @plugin 'tmux-plugins/tmux-yank'
 
 # enable mouse support
 set -g mouse on
@@ -40,7 +41,9 @@ bind % split-window -h -c "#{pane_current_path}"
 bind c new-window -c "#{pane_current_path}"
 
 # Use vim keybindings in copy mode
-setw -g mode-keys vi
+set-window-option -g mode-keys vi
+unbind -T copy-mode-vi MouseDragEnd1Pane
+bind-key -T copy-mode-vi y send-keys -X copy-selection
 
 # Initialize TMUX plugin manager (keep this line at the very bottom of tmux.conf)
 run '~/.dotfiles/external/tpm/tpm'