diff options
author | Alan Pearce | 2023-04-01 18:54:05 +0200 |
---|---|---|
committer | Alan Pearce | 2023-04-01 18:54:05 +0200 |
commit | 2264ae0becd3f21c469ad2c801af074810de6540 (patch) | |
tree | e9f67f4a434012ccaca2e6e8abc8800bb86f329a | |
parent | a3018e42941249ef2f03bf61d14e7dc6511ace78 (diff) | |
download | nixfiles-2264ae0becd3f21c469ad2c801af074810de6540.tar.lz nixfiles-2264ae0becd3f21c469ad2c801af074810de6540.tar.zst nixfiles-2264ae0becd3f21c469ad2c801af074810de6540.zip |
emacs: polyfill `project-name` for eglot
-rw-r--r-- | user/emacs/init.el | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/user/emacs/init.el b/user/emacs/init.el index f64bb226..f673b38c 100644 --- a/user/emacs/init.el +++ b/user/emacs/init.el @@ -1017,6 +1017,9 @@ _p_rev _u_pper _=_: upper/lower _r_esolve (use-package tree-sitter-indent :ghook ('(rustic-mode-hook))) +(unless (fboundp 'project-name) + (defun project-name (project) + (file-name-base (cdr project)))) (use-package eglot :general (:states 'normal :keymaps 'eglot-mode-map "gd" #'xref-find-definitions |