ADD save-symbol-at-point function
This was originally supplied by smartparens but I don't need the whole package for this function. Other functionality which I used from smartparens is available with electric-pair-mode .
This commit is contained in:
parent
9541cfbf44
commit
7329b044f3
1 changed files with 14 additions and 0 deletions
|
|
@ -379,3 +379,17 @@ https://github.com/remyferre/comment-dwim-2
|
|||
(define-key projectile-mode-map (kbd "C-x p") 'projectile-command-map)
|
||||
(projectile-mode +1)
|
||||
)
|
||||
|
||||
* Custom
|
||||
|
||||
** Save symbol at point
|
||||
|
||||
#+BEGIN_SRC emacs-lisp
|
||||
(defun myrmi/save-symbol-at-point ()
|
||||
"Make symbol at point the latest kill in the kill ring."
|
||||
(interactive)
|
||||
(let ((symbol (thing-at-point 'symbol)))
|
||||
(when symbol (kill-new symbol))))
|
||||
|
||||
(global-set-key (kbd "C-M-w") 'myrmi/save-symbol-at-point)
|
||||
#+END_SRC
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue