summaryrefslogtreecommitdiff
path: root/.config/emacs/init.el
diff options
context:
space:
mode:
authorThomas Voss <mail@thomasvoss.com> 2026-03-22 17:05:21 +0100
committerThomas Voss <mail@thomasvoss.com> 2026-03-22 17:05:21 +0100
commitf0e047b0674817c3fba38386a151c0b2ed620f50 (patch)
tree38598c348f7f536c2f0c302693856349639295d6 /.config/emacs/init.el
parent9a40ca3f9f198cb14c64c25edcf7c325ca2b8e5e (diff)
parentcb6831070008c56d3f287c4c754526d2c9d735a2 (diff)
Merge branch 'master' of github.com:Mango0x45/dotfilesHEADmaster
Diffstat (limited to '.config/emacs/init.el')
-rw-r--r--.config/emacs/init.el9
1 files changed, 9 insertions, 0 deletions
diff --git a/.config/emacs/init.el b/.config/emacs/init.el
index eb0f23e..0f917c7 100644
--- a/.config/emacs/init.el
+++ b/.config/emacs/init.el
@@ -73,6 +73,15 @@ This function is meant to be used in conjuction with `read-string' and
(string-to-number string-or-number)
string-or-number))
+(defun mm-camel-to-lisp (string)
+ "Convert STRING from camelCase to lisp-case."
+ (declare (ftype (function (string) string))
+ (pure t) (side-effect-free t))
+ (let ((case-fold-search nil))
+ (downcase
+ (replace-regexp-in-string
+ (rx (group (or lower digit)) (group upper)) "\\1-\\2" string))))
+
(defun mm-do-and-center (function &rest arguments)
"Call FUNCTION with ARGUMENTS and then center the screen."
(apply function arguments)