From 5d403d3e3b9205fa286b01b3fd32080dfbb7394f Mon Sep 17 00:00:00 2001 From: Franck Cuny Date: Wed, 23 Mar 2022 07:47:47 -0700 Subject: rename fcuny-edit to my-edit --- emacs/custom/fcuny-edit.el | 52 ---------------------------------------------- emacs/custom/my-edit.el | 50 ++++++++++++++++++++++++++++++++++++++++++++ emacs/init.el | 2 +- 3 files changed, 51 insertions(+), 53 deletions(-) delete mode 100644 emacs/custom/fcuny-edit.el create mode 100644 emacs/custom/my-edit.el (limited to 'emacs') diff --git a/emacs/custom/fcuny-edit.el b/emacs/custom/fcuny-edit.el deleted file mode 100644 index d40fd06..0000000 --- a/emacs/custom/fcuny-edit.el +++ /dev/null @@ -1,52 +0,0 @@ -;;; fcuny-edit.el --- Configure parts related to editing -;;; Commentary: -;;; Code: - -(require 'use-package) - -(use-package autorevert - :custom - (global-auto-revert-non-file-buffers t) - (auto-revert-verbose nil) - :config - (global-auto-revert-mode t)) - -(use-package whitespace - :hook ((prog-mode . fcuny/whitespace-setup) - (conf-mode . fcuny/whitespace-setup) - (outline-mode . fcuny/whitespace-setup) - (yaml-mode . fcuny/whitespace-setup)) - - :custom - (whitespace-style '(face)) - (show-trailing-whitespace nil) - - :init - (defun fcuny/whitespace-setup () - (setq show-trailing-whitespace t))) - -(use-package electric-pair-mode - :commands electric-pair-mode - :hook (prog-mode . electric-pair-mode)) - -(use-package paren - :ensure t - :custom - (show-paren-delay 0) - (show-paren-highlight-openparen t) - (show-paren-when-point-inside-paren t) - (show-paren-when-point-in-periphery t) - :config - (show-paren-mode 1)) - -(global-set-key (kbd "M-j") 'join-line) - -;; don't assume that sentences should have two spaces after period. -(setq sentence-end-double-space nil) - -;; switch to view-mode whenever you are in a read-only buffer (e.g. -;; switched to it using C-x C-q). -(setq view-read-only t) - -(provide 'fcuny-edit) -;;; fcuny-edit.el ends here diff --git a/emacs/custom/my-edit.el b/emacs/custom/my-edit.el new file mode 100644 index 0000000..eecd557 --- /dev/null +++ b/emacs/custom/my-edit.el @@ -0,0 +1,50 @@ +;;; my-edit.el --- Configure parts related to editing +;;; Commentary: +;;; Code: + +(require 'use-package) + +(use-package autorevert + :custom + (global-auto-revert-non-file-buffers t) + (auto-revert-verbose nil) + :config + (global-auto-revert-mode t)) + +(use-package whitespace + :preface + (defun my/whitespace-setup () + (setq show-trailing-whitespace t)) + :hook ((prog-mode . my/whitespace-setup) + (conf-mode . my/whitespace-setup) + (outline-mode . my/whitespace-setup) + (yaml-mode . my/whitespace-setup)) + :custom + (whitespace-style '(face)) + (show-trailing-whitespace nil)) + +(use-package electric-pair-mode + :commands electric-pair-mode + :hook (prog-mode . electric-pair-mode)) + +(use-package paren + :ensure t + :custom + (show-paren-delay 0) + (show-paren-highlight-openparen t) + (show-paren-when-point-inside-paren t) + (show-paren-when-point-in-periphery t) + :config + (show-paren-mode 1)) + +(global-set-key (kbd "M-j") 'join-line) + +;; don't assume that sentences should have two spaces after period. +(setq sentence-end-double-space nil) + +;; switch to view-mode whenever you are in a read-only buffer (e.g. +;; switched to it using C-x C-q). +(setq view-read-only t) + +(provide 'my-edit) +;;; my-edit.el ends here diff --git a/emacs/init.el b/emacs/init.el index 7334f48..54dc616 100644 --- a/emacs/init.el +++ b/emacs/init.el @@ -41,7 +41,7 @@ (require 'my-settings (expand-file-name "custom/my-settings" user-emacs-directory)) (require 'my-ui (expand-file-name "custom/my-ui" user-emacs-directory)) (require 'my-navigation (expand-file-name "custom/my-navigation" user-emacs-directory)) -(require 'fcuny-edit (expand-file-name "custom/fcuny-edit" user-emacs-directory)) +(require 'my-edit (expand-file-name "custom/my-edit" user-emacs-directory)) (require 'fcuny-text (expand-file-name "custom/fcuny-text" user-emacs-directory)) (require 'fcuny-git (expand-file-name "custom/fcuny-git" user-emacs-directory)) (require 'fcuny-org (expand-file-name "custom/fcuny-org" user-emacs-directory)) -- cgit 1.4.1