summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJSDurand <mmemmew@gmail.com>2021-03-01 13:28:28 +0800
committerJSDurand <mmemmew@gmail.com>2021-03-01 13:28:28 +0800
commit0062c1cf5df981e570c87c83faf11fd607b05356 (patch)
tree738887435b1f7144f913f13117794ae68c717382
parentf76ba0b6608072532f9a13b5b607c43aad12f159 (diff)
Add the first skeleton
* init.el (prepare-skeletons): Lazy load this. * skeleton-conf.el (skeleton-conf): (insert-define-key): This is only a primitive skeleton. I will add more in the future.
-rw-r--r--init.el3
-rw-r--r--skeleton-conf.el39
2 files changed, 42 insertions, 0 deletions
diff --git a/init.el b/init.el
index 7f7ee4e..db95561 100644
--- a/init.el
+++ b/init.el
@@ -131,6 +131,9 @@ no effect."
(add-to-list 'auto-mode-alist (cons "pdf$" #'pdf-view-mode))
;;;###autoload
+(load-after-function prepare-skeletons "skeleton-conf.el" "Load skeletons." nil)
+
+;;;###autoload
(load-after-function pdf-view-mode "pdf.el" "Fake mode that loads the pacakge." nil
(pdf-view-mode))
diff --git a/skeleton-conf.el b/skeleton-conf.el
new file mode 100644
index 0000000..a1dfaaf
--- /dev/null
+++ b/skeleton-conf.el
@@ -0,0 +1,39 @@
+;;; skeleton-conf.el --- Configurations of skeletons -*- lexical-binding: t; -*-
+
+;; Copyright (C) 2021 李俊緯
+
+;; Author: 李俊緯 <mmemmew@gmail.com>
+;; Keywords: abbrev, convenience, wp
+
+;; This program is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation, either version 3 of the License, or
+;; (at your option) any later version.
+
+;; This program is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with this program. If not, see <https://www.gnu.org/licenses/>.
+
+;;; Commentary:
+
+;; This is the file of my configurations of skeletons.
+
+;;; Code:
+
+;;;###autoload
+(define-skeleton insert-define-key "Insert a define-key statement."
+ "define key"
+ "(define-key "
+ '(recursive-edit)
+ " (vector "
+ '(recursive-edit)
+ ") #'"
+ '(recursive-edit)
+ ")")
+
+(provide 'skeleton-conf)
+;;; skeleton-conf.el ends here