mirror of
https://github.com/pestctrl/emacs-config.git
synced 2026-06-14 12:21:20 +00:00
Moved headers to ext
This commit is contained in:
parent
457446d47a
commit
16639d6847
2 changed files with 41 additions and 41 deletions
|
|
@ -1023,47 +1023,6 @@
|
|||
;; (t . 24)))
|
||||
;; '((swiper . 24)))
|
||||
#+end_src
|
||||
** Setup convenient headers
|
||||
#+begin_src emacs-lisp
|
||||
(setq auto-insert-alist
|
||||
'(((emacs-lisp-mode . "Emacs lisp mode") nil
|
||||
";;; " (file-name-nondirectory buffer-file-name) " --- " _ " -*- lexical-binding: t -*-\n\n"
|
||||
|
||||
";; Copyright (C) " (format-time-string "%Y") " Benson Chu\n\n"
|
||||
|
||||
";; Author: Benson Chu <bensonchu457@gmail.com>\n"
|
||||
";; Created: " (format-time-string "[%Y-%m-%d %H:%M]") "\n\n"
|
||||
|
||||
";; This file is not part of GNU Emacs\n\n"
|
||||
|
||||
";; This program is free software: you can redistribute it and/or modify\n"
|
||||
";; it under the terms of the GNU General Public License as published by\n"
|
||||
";; the Free Software Foundation, either version 3 of the License, or\n"
|
||||
";; (at your option) any later version.\n\n"
|
||||
|
||||
";; This program is distributed in the hope that it will be useful,\n"
|
||||
";; but WITHOUT ANY WARRANTY; without even the implied warranty of\n"
|
||||
";; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n"
|
||||
";; GNU General Public License for more details.\n\n"
|
||||
|
||||
";; You should have received a copy of the GNU General Public License\n"
|
||||
";; along with this program. If not, see <https://www.gnu.org/licenses/>.\n\n"
|
||||
|
||||
";;; Commentary:\n\n"
|
||||
|
||||
";;; Code:\n\n"
|
||||
|
||||
"(provide '" (file-name-sans-extension (file-name-nondirectory buffer-file-name)) ")\n"
|
||||
";;; " (file-name-nondirectory buffer-file-name) " ends here\n")
|
||||
((lisp-mode . "Common Lisp") nil
|
||||
"(defpackage :" (file-name-sans-extension (file-name-nondirectory buffer-file-name)) "\n"
|
||||
" (:use :cl :alexandria)\n"
|
||||
" (:export))\n\n"
|
||||
|
||||
"(in-package :" (file-name-sans-extension (file-name-nondirectory buffer-file-name)) ")")))
|
||||
|
||||
(auto-insert-mode)
|
||||
#+end_src
|
||||
** read-identifier too slow
|
||||
#+begin_src emacs-lisp
|
||||
(add-to-list 'xref-prompt-for-identifier
|
||||
|
|
|
|||
|
|
@ -417,3 +417,44 @@
|
|||
mouse-wheel-scroll-amount '(3)
|
||||
mouse-wheel-progressive-speed nil)
|
||||
#+END_SRC
|
||||
** Setup convenient headers
|
||||
#+begin_src emacs-lisp
|
||||
(setq auto-insert-alist
|
||||
'(((emacs-lisp-mode . "Emacs lisp mode") nil
|
||||
";;; " (file-name-nondirectory buffer-file-name) " --- " _ " -*- lexical-binding: t -*-\n\n"
|
||||
|
||||
";; Copyright (C) " (format-time-string "%Y") " Benson Chu\n\n"
|
||||
|
||||
";; Author: Benson Chu <bensonchu457@gmail.com>\n"
|
||||
";; Created: " (format-time-string "[%Y-%m-%d %H:%M]") "\n\n"
|
||||
|
||||
";; This file is not part of GNU Emacs\n\n"
|
||||
|
||||
";; This program is free software: you can redistribute it and/or modify\n"
|
||||
";; it under the terms of the GNU General Public License as published by\n"
|
||||
";; the Free Software Foundation, either version 3 of the License, or\n"
|
||||
";; (at your option) any later version.\n\n"
|
||||
|
||||
";; This program is distributed in the hope that it will be useful,\n"
|
||||
";; but WITHOUT ANY WARRANTY; without even the implied warranty of\n"
|
||||
";; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n"
|
||||
";; GNU General Public License for more details.\n\n"
|
||||
|
||||
";; You should have received a copy of the GNU General Public License\n"
|
||||
";; along with this program. If not, see <https://www.gnu.org/licenses/>.\n\n"
|
||||
|
||||
";;; Commentary:\n\n"
|
||||
|
||||
";;; Code:\n\n"
|
||||
|
||||
"(provide '" (file-name-sans-extension (file-name-nondirectory buffer-file-name)) ")\n"
|
||||
";;; " (file-name-nondirectory buffer-file-name) " ends here\n")
|
||||
((lisp-mode . "Common Lisp") nil
|
||||
"(defpackage :" (file-name-sans-extension (file-name-nondirectory buffer-file-name)) "\n"
|
||||
" (:use :cl :alexandria)\n"
|
||||
" (:export))\n\n"
|
||||
|
||||
"(in-package :" (file-name-sans-extension (file-name-nondirectory buffer-file-name)) ")")))
|
||||
|
||||
(auto-insert-mode)
|
||||
#+end_src
|
||||
|
|
|
|||
Loading…
Reference in a new issue