diff --git a/vim/.vimrc b/vim/.vimrc index aaf7725..16f35e7 100644 --- a/vim/.vimrc +++ b/vim/.vimrc @@ -45,7 +45,8 @@ let g:clang_format#style_options = { \ 'SpaceBeforeParens': 'ControlStatements' \ } -autocmd BufWritePre *.c,*.h call system('clang-format -i ' . shellescape(@%)) | edit! +autocmd BufWritePre *.c,*.h silent! execute '%!clang-format' +"autocmd BufWritePre *.c,*.h call system('clang-format -i ' . shellescape(@%)) " ---------------------------------------- " General UI settings