From e43b996df685e5031367976bd76bfc660880c981 Mon Sep 17 00:00:00 2001 From: Case Duckworth Date: Mon, 30 Aug 2021 22:18:45 -0500 Subject: Reorganize --- init.el | 47 +++++++++++++++++++++++++---------------------- 1 file changed, 25 insertions(+), 22 deletions(-) (limited to 'init.el') diff --git a/init.el b/init.el index acdea0c..0bc68be 100644 --- a/init.el +++ b/init.el @@ -1745,8 +1745,8 @@ successive invocations." (setup (:straight persistent-scratch) (:option persistent-scratch-backup-directory (acdw/dir "scratch" t) - persistent-scratch-keep-n-newest-backups 12)) -(persistent-scratch-setup-default)) + persistent-scratch-keep-n-newest-backups 12) + (persistent-scratch-setup-default)) (setup (:straight restart-emacs) (defun emacs-upgrade (&optional update-packages) @@ -1835,24 +1835,7 @@ successive invocations." (:hook-into prog-mode)) (setup (:straight typo) - - ;; jlf & cvandusen on #emacs make a great point: ’ (RIGHT SINGLE QUOTATION - ;; MARK) is /not/ an apostrophe. Making it curly is a typographical - ;; consideration, not an input consideration. (I suppose you could make the - ;; argument that all of these are typographical considerations, but .. bleh.) - (define-typo-cycle typo-cycle-apostrophe - "Cycle through apostrophe-like graphemes. -If used with a numeric prefix argument N, N apostrophes will be inserted." - ("'" "′" "″" "’")) - - (define-typo-cycle typo-cycle-backtick - "Cycle through backtick and left single quotation mark. -If used with a numeric prefix argument N, N backticks will be inserted." - ("`" "‘")) - - (:bind "'" typo-cycle-apostrophe - "`" typo-cycle-backtick) - + ;; Enable C-c 8 map in all buffers (typo-global-mode +1) @@ -1863,10 +1846,30 @@ If used with a numeric prefix argument N, N backticks will be inserted." ;; `typo-disable-electricity-functions' because the latter checks ;; on every pertinent keypress. I know I want /no/ typo-ing in ;; these certain buffers, so I won't even turn on the mode. - (unless (or ; predicates here + (unless (or ; predicates here (string-match-p "COMMIT_EDITMSG" (or (buffer-name) ""))) - (typo-mode +1))))) + (typo-mode +1)))) + + (with-eval-after-load 'typo + ;; jlf & cvandusen on #emacs make a great point: ’ (RIGHT SINGLE QUOTATION + ;; MARK) is /not/ an apostrophe. Making it curly is a typographical + ;; consideration, not an input consideration. (I suppose you could make + ;; the argument that all of these are typographical considerations, but + ;; .. bleh.) + (define-typo-cycle typo-cycle-apostrophe + "Cycle through apostrophe-like graphemes. +If used with a numeric prefix argument N, N apostrophes will be inserted." + ("'" "′" "″" "’")) + + (define-typo-cycle typo-cycle-backtick + "Cycle through backtick and left single quotation mark. +If used with a numeric prefix argument N, N backticks will be inserted." + ("`" "‘")) + + (:bind "'" typo-cycle-apostrophe + "`" typo-cycle-backtick) + )) (setup (:straight undo-fu) (:global "C-/" undo-fu-only-undo -- cgit 1.4.1-21-gabe81