[ADD][VIM] Beancount filetype configuration

This commit is contained in:
Bruno BELANYI 2020-07-15 02:10:46 +02:00
parent 79eaa9aeda
commit 11890af357

View file

@ -0,0 +1,13 @@
" Create the `b:undo_ftplugin` variable if it doesn't exist
call ftplugined#check_undo_ft()
" Use a small indentation value on beancount files
setlocal shiftwidth=2
let b:undo_ftplugin.='|setlocal shiftwidth<'
" Have automatic padding of transactions so that decimal is on 52nd column
let g:beancount_separator_col=52
" Automatic padding for transactions
nnoremap <buffer> <leader>= :AlignCommodity<CR>
vnoremap <buffer> <leader>= :AlignCommodity<CR>