From d210da1542c8b0599e63823d0197c57faee9a8f7 Mon Sep 17 00:00:00 2001 From: tavo-wasd Date: Thu, 23 May 2024 21:14:17 -0600 Subject: [PATCH] c/cpp gcc vim compiler --- vim/after/plugin/nohiquickfix.vim | 1 + vim/vimrc | 12 ++++++++++++ 2 files changed, 13 insertions(+) create mode 100644 vim/after/plugin/nohiquickfix.vim diff --git a/vim/after/plugin/nohiquickfix.vim b/vim/after/plugin/nohiquickfix.vim new file mode 100644 index 0000000..0ce23e7 --- /dev/null +++ b/vim/after/plugin/nohiquickfix.vim @@ -0,0 +1 @@ +hi QuickFixLine ctermfg=NONE cterm=bold guifg=NONE gui=bold diff --git a/vim/vimrc b/vim/vimrc index 1eff39c..3abf809 100644 --- a/vim/vimrc +++ b/vim/vimrc @@ -58,6 +58,18 @@ noremap H :nohl noremap za noremap N /@@@ +autocmd QuickFixCmdPost [^l]* nested cwindow +autocmd QuickFixCmdPost l* nested lwindow +noremap m :make +noremap :make +noremap p :cp +noremap n :cn +noremap n :cn + +" c/c++ +autocmd FileType c :compiler gcc | setlocal makeprg=gcc\ -Wall\ -c\ %\ &&\ rm\ -f\ %.gch +autocmd FileType cpp :compiler gcc | setlocal makeprg=g++\ -Wall\ -c\ %\ &&\ rm\ -f\ %.gch + " groff autocmd FileType groff noremap :!zathura --fork %:r.pdf & disown autocmd FileType groff noremap :w :!groffc %