From d035ee3e9c523ef0f1c00f8ecc1e930ed4abc13e Mon Sep 17 00:00:00 2001 From: Stefan Junker Date: Sat, 3 Sep 2016 12:48:19 +0200 Subject: [PATCH] shell.nix: tweak vimrc --- shell.nix | 28 +++++++++++----------------- 1 file changed, 11 insertions(+), 17 deletions(-) diff --git a/shell.nix b/shell.nix index 1f98f05..21373fd 100644 --- a/shell.nix +++ b/shell.nix @@ -36,10 +36,9 @@ in pkgs.stdenv.mkDerivation { noremap :tabn noremap :tabp let g:ctrlp_map = '' - set wildignore+=*/site/*,*.so,*.swp,*.zip let g:ctrlp_custom_ignore = { \ 'dir': '\v[\/]\.(git|hg|svn|)$$', - \ 'file': '\v\.(exe|so|dll)$$', + \ 'file': '\v\.(exe|so|dll|so|swp|zip|aux|log|fdb_latexmk|fdb|dvi|lof|lot|pdf|fls|toc|gz|latexmain)$$', \ } " allways show status line @@ -50,17 +49,6 @@ in pkgs.stdenv.mkDerivation { set expandtab "set textwidth=80 - set wildignore+=*/site/*,*.so,*.swp,*.zip - let g:ctrlp_custom_ignore = { - \ 'dir': '\v[\/]\.(git|hg|svn|)$$', - \ 'file': '\v\.(exe|so|dll)$$', - \ } - " } - - " spelling {{{ - au BufRead,BufNewFile *.md,*.markdown setlocal spell spelllang=en_us,de_de - " }}} - " sync default register to clipboard { if has('unnamedplus') set clipboard=unnamedplus @@ -96,6 +84,11 @@ in pkgs.stdenv.mkDerivation { au Syntax * RainbowParenthesesLoadSquare au Syntax * RainbowParenthesesLoadBraces " } + set backspace=indent,eol,start + colorscheme PaperColor + + " Latex Related {{{ + au BufRead,BufNewFile *.tex,*.md,*.markdown setlocal spell spelllang=en_us let g:vimtex_view_method = 'zathura' @@ -105,7 +98,6 @@ in pkgs.stdenv.mkDerivation { let g:vimtex_indent_enabled = 1 let g:vimtex_indent_bib_enabled = 1 - if !exists('g:ycm_semantic_triggers') let g:ycm_semantic_triggers = {} endif @@ -120,15 +112,17 @@ in pkgs.stdenv.mkDerivation { \ 're!\\includestandalone(\s*\[[^]]*\])?\s*\{[^}]*', \ ] - set t_ut= - colorscheme PaperColor + function! ViewerCallback() dict + call self.forward_search(self.out) + endfunction + let g:vimtex_view_zathura_hook_callback = 'ViewerCallback' + " }}} ''; vam.knownPlugins = pkgs.vimPlugins; vam.pluginDictionaries = [ "youcompleteme" "vim-airline" - "vim-addon-nix" "ctrlp" "vim-css-color" "rainbow_parentheses"