From d23a175533ebc04fa5c8a9712118cc5bf509adf0 Mon Sep 17 00:00:00 2001 From: Maxime Coste Date: Tue, 31 Jan 2012 14:07:41 +0000 Subject: [PATCH] insert include guards in C++ header files at creation --- src/rc/cpp.kak | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/rc/cpp.kak b/src/rc/cpp.kak index 12ecaac33..1411c5391 100644 --- a/src/rc/cpp.kak +++ b/src/rc/cpp.kak @@ -11,3 +11,6 @@ hook global WinCreate .*\.(c|cc|cpp|cxx|C|h|hh|hpp|hxx|H) \ addfilter cleanup_whitespaces; \ hook window InsertEnd .* exec xs\h+(?=\n)d +hook global BufCreate .*\.(h|hh|hpp|hxx|H) \ + exec ggi%ggxs\.c_A_INCLUDEDxyppI#ifndefjI#definejI#endif//O +