about summary refs log tree commit diff stats
path: root/.emacs.d/lisp/init-editor.el
diff options
context:
space:
mode:
authorDavid Morgan <djm_uk@protonmail.com>2022-08-30 12:47:42 +0100
committerDavid Morgan <djm_uk@protonmail.com>2022-08-30 12:47:42 +0100
commitc3664816ad67559eefa0c124cc0598a52c5feacd (patch)
treef5a59758281714087ba57f08ee366dc9f96fd9f9 /.emacs.d/lisp/init-editor.el
parentb8035c906cca47395c04afef83c724d86e1e48aa (diff)
downloaddotfiles-c3664816ad67559eefa0c124cc0598a52c5feacd.tar.gz
Remove some unnecessary config
Diffstat (limited to '.emacs.d/lisp/init-editor.el')
-rw-r--r--.emacs.d/lisp/init-editor.el28
1 files changed, 0 insertions, 28 deletions
diff --git a/.emacs.d/lisp/init-editor.el b/.emacs.d/lisp/init-editor.el
index 0412618..6999285 100644
--- a/.emacs.d/lisp/init-editor.el
+++ b/.emacs.d/lisp/init-editor.el
@@ -53,34 +53,6 @@
   (set-selection-coding-system 'utf-8)
   (prefer-coding-system 'utf-8)
   (setq default-process-coding-system '(utf-8-unix . utf-8-unix))
-
-  (defadvice set-buffer-major-mode (after set-major-mode activate compile)
-    "Set buffer major mode according to `auto-mode-alist'."
-    (let* ((name (buffer-name buffer))
-           (mode (assoc-default name auto-mode-alist 'string-match)))
-      (when (and mode (consp mode))
-        (setq mode (car mode)))
-      (with-current-buffer buffer (if mode (funcall mode)))))
-
-  (defadvice server-visit-files (before parse-numbers-in-lines (files proc &optional nowait) activate)
-    "Open file with emacsclient with cursors positioned on requested line.
-Most of console-based utilities prints filename in format
-'filename:linenumber'.  So you may wish to open filename in that format.
-Just call:
-
-  emacsclient filename:linenumber
-
-and file 'filename' will be opened and cursor set on line 'linenumber'"
-    (ad-set-arg 0
-                (mapcar (lambda (fn)
-                          (let ((name (car fn)))
-                            (if (string-match "^\\(.*?\\):\\([0-9]+\\)\\(?::\\([0-9]+\\)\\)?$" name)
-                                (cons
-                                 (match-string 1 name)
-                                 (cons (string-to-number (match-string 2 name))
-                                       (string-to-number (or (match-string 3 name) ""))))
-                              fn))) files)))
-
   (set-default 'imenu-auto-rescan t))
 
 (use-package move-text