mirror of
https://github.com/gryf/.vim.git
synced 2026-02-11 13:25:45 +01:00
Added branch pathogen
This commit is contained in:
16
bundle/ft_rst/ftplugin/rst/commons.vim
Normal file
16
bundle/ft_rst/ftplugin/rst/commons.vim
Normal file
@@ -0,0 +1,16 @@
|
||||
" Some common settings for all reSt files
|
||||
setlocal textwidth=80
|
||||
setlocal makeprg=rst2html.py\ \"%\"\ \"%:p:r.html\"
|
||||
setlocal spell
|
||||
setlocal smartindent
|
||||
setlocal autoindent
|
||||
setlocal formatoptions=tcq "set VIms default
|
||||
|
||||
let g:blogger_login="gryf73"
|
||||
let g:blogger_name="rdobosz"
|
||||
let g:blogger_browser=1
|
||||
let g:blogger_stylesheets=["css/widget_css_2_bundle.css", "css/style_custom.css", "css/style_blogger.css", "css/wombat_pygments.css", "css/lucius_pygments.css"]
|
||||
let g:blogger_pygments_class="wombat"
|
||||
|
||||
map <F6> :PreviewBlogArticle<cr>
|
||||
map <F7> :SendBlogArticle<cr>
|
||||
29
bundle/ft_rst/ftplugin/rst/word_utils.vim
Normal file
29
bundle/ft_rst/ftplugin/rst/word_utils.vim
Normal file
@@ -0,0 +1,29 @@
|
||||
function! WordFrequency() range
|
||||
let all = split(join(getline(a:firstline, a:lastline)), '\k\+')
|
||||
let frequencies = {}
|
||||
for word in all
|
||||
let frequencies[word] = get(frequencies, word, 0) + 1
|
||||
endfor
|
||||
new
|
||||
setlocal buftype=nofile bufhidden=hide noswapfile tabstop=4
|
||||
for [key,value] in items(frequencies)
|
||||
call append('$', value."\t".key)
|
||||
endfor
|
||||
sort i
|
||||
endfunction
|
||||
command! -range=% WordFrequency <line1>,<line2>call WordFrequency()
|
||||
|
||||
function! CreateDict() range
|
||||
let all = split(join(getline(a:firstline, a:lastline)), '[^A-Za-zęóąśłżźćńĘÓĄŚŁŻŹĆŃ]\+')
|
||||
let frequencies = {}
|
||||
for word in all
|
||||
let frequencies[word] = get(frequencies, word, 0) + 1
|
||||
endfor
|
||||
new
|
||||
setlocal buftype=nofile bufhidden=hide noswapfile
|
||||
for [key,value] in items(frequencies)
|
||||
call append('$', key)
|
||||
endfor
|
||||
sort i
|
||||
endfunction
|
||||
command! -range=% CreateDict <line1>,<line2>call CreateDict()
|
||||
Reference in New Issue
Block a user