-
Notifications
You must be signed in to change notification settings - Fork 0
/
.vimrc
94 lines (82 loc) · 3.02 KB
/
.vimrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
" =============================================================================
" FileName : .vimrc
" Author : [email protected]
" Created : 2010-10
" Version : 2.0.1
" LastChange : 2024-08-22 23:19:15
" =============================================================================
runtime macros/matchit.vim
runtime defaults.vim
let performance_mode = 1
set nocompatible
set wildignore+=*/tmp/*,*.so,*.swp,*.zip
source ~/.marslo/vimrc.d/os
if IsWindows() | source $HOME\.vim\autoload\plug.vim | endif
set runtimepath+=~/.vim/plugged
if IsMac() || IsWindows()
set spellcapcheck=1
else " if has('unix')
set spellcapcheck=0
endif
" python, git, shell environment
if IsGitBash() || IsNuShell()
let g:python3_host_prog = 'c:\iMarslo\myprograms\Python312\python.exe'
let g:gitgutter_git_executable = '/mingw64/bin/git'
elseif IsWindows()
let g:python3_host_prog = 'c:\iMarslo\myprograms\Python312\python.exe'
let g:gitgutter_git_executable = 'c:\iMarslo\myprograms\Git\bin\git.exe'
" set shell=C:\iMarslo\myprograms\Git\bin\bash.exe
else
let g:python3_host_prog = expand(trim( system('command -v python3') ))
let g:gitgutter_git_executable = expand(trim( system('command -v git') ))
set shell=/usr/bin/bash
endif
if IsMac() | set shell=/usr/local/bin/bash | endif " let &shell = '/usr/local/bin/bash'
if executable( 'bash' ) | set shellcmdflag=-c | endif " let &shellcmdflag = '-c'
if filereadable( '/usr/local/opt/fzf' )
set runtimepath+=/usr/local/opt/fzf
elseif filereadable( '~/.marslo/bin/fzf' )
set runtimepath+=~/.marslo/bin/fzf
endif
if has( 'nvim' )
set viminfo=%,<800,'10,/50,:100,h,f0,n~/.vim/cache/.nviminfo
else
if version > 74399 | set cryptmethod=blowfish2 | endif
set viminfo=%,<800,'10,/50,:100,h,f0,n~/.vim/cache/.viminfo
set ttymouse=xterm2
endif
if empty( glob('~/.vim/cache/') ) | execute 'silent !mkdir -p ~/.vim/cache' | endif
source ~/.marslo/vimrc.d/extension
if has( 'vim' ) | source ~/.marslo/vimrc.d/extra-extension | endif
source ~/.marslo/vimrc.d/functions
source ~/.marslo/vimrc.d/cmds
source ~/.marslo/vimrc.d/theme
source ~/.marslo/vimrc.d/settings
source ~/.marslo/vimrc.d/shortcuts
source ~/.marslo/vimrc.d/autocmd
source ~/.marslo/vimrc.d/highlight
if ! IsWSL() && ! IsMac() | source ~/.marslo/vimrc.d/unix | endif
if IsWSL()
set clipboard=unnamed
set clipboard=unnamedplus
else
set clipboard+=unnamed
set clipboard+=unnamedplus
endif
if has( 'persistent_undo' )
if has('nvim')
let target_path = expand( '~/.vim/undo' )
set undodir=expand('~/.vim/undo')
else
let target_path = expand( '~/.vim/undo/vundo' )
endif
if !isdirectory( target_path )
call system( 'mkdir -p ' . target_path )
endif
set undofile
let &undodir=target_path
endif
if empty( glob('$HOME/.vim/autoload/plug.vim') ) || empty( glob($VIM . 'autoload\plug.vim') )
execute 'silent exec "GetPlug"'
endif
" vim:tabstop=2:softtabstop=2:shiftwidth=2:expandtab:filetype=vim