(Emacs)+header auto-insert with copyright notice.

This commit is contained in:
2023-09-28 16:29:19 +01:00
parent 08679e967a
commit 790d4dc86e

View File

@@ -3092,6 +3092,16 @@ Tons of stuff, namely:
" * Description: " _ "\n"
" */\n"
"\n")
(("\\.\\([Hh]\\|hh\\|hpp\\|hxx\\|h\\+\\+\\)\\'" . "C / C++ header")
(replace-regexp-in-string "[^A-Z0-9]" "_"
(string-replace "+" "P"
(upcase
(file-name-nondirectory buffer-file-name))))
"/* " (+license/insert-copyright-notice) "\n\n"
" * Created: " (format-time-string "%Y-%m-%d") "\n"
" * Author: " user-full-name "\n"
" * Description: " _ "\n*/"
"#ifndef " str n "#define " str "\n\n" "\n\n#endif")
:config
(c-add-style
"user"