From 537cc93fc967e18301126f0a19184c0e78728b38 Mon Sep 17 00:00:00 2001 From: tdro Date: Wed, 20 Oct 2021 03:43:42 -0400 Subject: .vimrc: Bring back nim for a few scripts --- .vimrc | 4 ++++ 1 file changed, 4 insertions(+) (limited to '.vimrc') diff --git a/.vimrc b/.vimrc index c22abeb..296c38f 100644 --- a/.vimrc +++ b/.vimrc @@ -308,6 +308,7 @@ augroup AutoCommands autocmd FileType html autocmd! BufWritePost exe 'Notify(''prettier --write --parser html ' . expand('%') . ' 2>&1'')' | :e autocmd FileType python autocmd! BufWritePost exe 'Notify(''black ' . expand('%') . ' 2>&1 && pylint ' . expand('%') . ' 2>&1'')' | :e autocmd FileType ruby autocmd! BufWritePost exe 'Notify(''rufo ' . expand('%') . ' 2>&1 && rubocop ' . expand('%') . ' 2>&1'')' | :e + autocmd FileType nim autocmd! BufWritePost exe 'Notify(''nimpretty ' . expand('%') . ' 2>&1 && printf "Nim OK: ' . expand('%') . '"'')' | :e autocmd FileType rust autocmd! BufWritePost exe 'Notify(''rustfmt ' . expand('%') . ' 2>&1 && printf "rustfmt OK: ' . expand('%') . '"'')' | :e autocmd FileType json autocmd! BufWritePost exe 'Notify(''jsonlint -i ' . expand('%') . ' 2>&1 && printf "JSON OK: ' . expand('%') . '"'')' | :e autocmd FileType elixir autocmd! BufWritePost exe 'Notify(''mix format ' . expand('%') . ' 2>&1 && printf "Elixir Format OK: ' . expand('%') . '"'')' | :e @@ -345,6 +346,9 @@ augroup AutoCommands autocmd FileType nix set formatprg=nixfmt autocmd FileType sh set formatprg=shfmt\ - + " Set file types. + autocmd BufRead,BufNewFile *.nims set filetype=nim + " General auto commands. autocmd BufWritePost *.tex :term ++close ++rows=10 latex-compile % autocmd BufWritePost $HOME/.config/chromexup/config.ini exe 'Notify(''chromexup 2>&1'')' -- cgit v1.2.3