mirror of
https://github.com/gryf/.vim.git
synced 2025-12-17 11:30:29 +01:00
Added vimwiki filetype settings
This commit is contained in:
15
vimrc
15
vimrc
@@ -236,7 +236,7 @@ function s:SetPythonSettings() "{{{2
|
|||||||
"autocmd FileType python setlocal omnifunc=pysmell#Complete
|
"autocmd FileType python setlocal omnifunc=pysmell#Complete
|
||||||
let python_highlight_all=1
|
let python_highlight_all=1
|
||||||
|
|
||||||
"I don't want to have pyflakes errors in qfix, it interfering with
|
"I don't want to have pyflakes errors in qfix, it interfering with
|
||||||
"Pep8/Pylint
|
"Pep8/Pylint
|
||||||
let g:pyflakes_use_quickfix = 0
|
let g:pyflakes_use_quickfix = 0
|
||||||
|
|
||||||
@@ -244,7 +244,7 @@ function s:SetPythonSettings() "{{{2
|
|||||||
autocmd BufWinLeave *.py mkview
|
autocmd BufWinLeave *.py mkview
|
||||||
autocmd BufWinEnter *.py silent loadview
|
autocmd BufWinEnter *.py silent loadview
|
||||||
|
|
||||||
"Something bad happens for python comments - it places 2 spaces instead
|
"Something bad happens for python comments - it places 2 spaces instead
|
||||||
"of 1 after the # sign. Workaround:
|
"of 1 after the # sign. Workaround:
|
||||||
let g:NERDCustomDelimiters = {'python': {'left': '#'}}
|
let g:NERDCustomDelimiters = {'python': {'left': '#'}}
|
||||||
let g:NERDSpaceDelims = 0
|
let g:NERDSpaceDelims = 0
|
||||||
@@ -356,7 +356,7 @@ function s:SetRestSettings() "{{{2
|
|||||||
command! -range=% WordFrequency <line1>,<line2>call WordFrequency()
|
command! -range=% WordFrequency <line1>,<line2>call WordFrequency()
|
||||||
|
|
||||||
function! CreateDict() range
|
function! CreateDict() range
|
||||||
let all = split(join(getline(a:firstline, a:lastline)),
|
let all = split(join(getline(a:firstline, a:lastline)),
|
||||||
\ '[^A-Za-zęóąśłżźćńĘÓĄŚŁŻŹĆŃ]\+')
|
\ '[^A-Za-zęóąśłżźćńĘÓĄŚŁŻŹĆŃ]\+')
|
||||||
let frequencies = {}
|
let frequencies = {}
|
||||||
for word in all
|
for word in all
|
||||||
@@ -373,6 +373,12 @@ function s:SetRestSettings() "{{{2
|
|||||||
|
|
||||||
endfunction
|
endfunction
|
||||||
"}}}
|
"}}}
|
||||||
|
function s:SetVimwikiSettings() "{{{2
|
||||||
|
map <F5> :Vimwiki2HTML<CR>
|
||||||
|
map <S-F5> :Vimwiki2HTMLBrowse<CR>
|
||||||
|
map <C-F5> :VimwikiAll2HTML<CR>
|
||||||
|
endfunction
|
||||||
|
"}}}
|
||||||
|
|
||||||
"remove all trailing whitespace for specified files before write
|
"remove all trailing whitespace for specified files before write
|
||||||
autocmd BufWritePre * :call <SID>StripTrailingWhitespaces(0, 'n')
|
autocmd BufWritePre * :call <SID>StripTrailingWhitespaces(0, 'n')
|
||||||
@@ -395,6 +401,7 @@ autocmd FileType snippet call <SID>SetSnippetSettings()
|
|||||||
autocmd FileType sql call <SID>SetSqlSettings()
|
autocmd FileType sql call <SID>SetSqlSettings()
|
||||||
autocmd FileType markdown call <SID>SetMarkdownSettings()
|
autocmd FileType markdown call <SID>SetMarkdownSettings()
|
||||||
autocmd FileType vim call <SID>SetVimSettings()
|
autocmd FileType vim call <SID>SetVimSettings()
|
||||||
|
autocmd FileType vimwiki call <SID>SetVimwikiSettings()
|
||||||
|
|
||||||
" }}}
|
" }}}
|
||||||
"TERMINAL: options for terminal emulators {{{
|
"TERMINAL: options for terminal emulators {{{
|
||||||
@@ -543,8 +550,6 @@ map <Leader>wp <Plug>VimwikiPrevWord
|
|||||||
"}}}
|
"}}}
|
||||||
" FUNCTIONS: usefull functions for all of the files {{{
|
" FUNCTIONS: usefull functions for all of the files {{{
|
||||||
|
|
||||||
" Switch VCSCommand current used VCS system
|
|
||||||
|
|
||||||
" Simple wrapper for :make command
|
" Simple wrapper for :make command
|
||||||
function <SID>Make()
|
function <SID>Make()
|
||||||
echohl Statement
|
echohl Statement
|
||||||
|
|||||||
Reference in New Issue
Block a user