For now it is just few lines in my vimrc

This commit is contained in:
əlemi 2019-10-22 12:04:54 +02:00
parent df50436331
commit b8cd7ebbfa
Signed by: alemi
GPG key ID: A4895B84D311642C

19
vimrc Normal file
View file

@ -0,0 +1,19 @@
" COMBO Counter
let g:combo_counter = 0
let g:best_combo = readfile('/home/$USER/.vim/.combo')
let g:best_combo = g:best_combo[0]
let g:last_combo = reltime()
let g:airline_section_b = 'ᛥ %{g:combo_counter} [%{g:best_combo}]'
function! UpdateCombo()
if reltimefloat(reltime(g:last_combo)) > 1
let g:combo_counter = 1
else
let g:combo_counter +=1
if g:combo_counter > g:best_combo
call writefile([g:combo_counter], "/home/$USER/.vim/.combo")
let g:best_combo = g:combo_counter
endif
endif
let g:last_combo = reltime()
endfunction
autocmd CursorMovedI * call UpdateCombo()