Compare commits

...
2 Commits
Author SHA1 Message Date
msyds b91a681072 fix(emacs): disable lsp formatting
build / build (push) Failing after 43s
2026-07-07 16:43:23 -06:00
msyds 5d502329a2 fix(emacs): don't import TERM from systemd 2026-07-07 16:40:01 -06:00
2 changed files with 22 additions and 16 deletions
@@ -25,8 +25,12 @@
:general (:keymaps 'syd-leader-code-map
"a" #'lsp-execute-code-action
"r" #'lsp-rename)
:custom (; Fixes type error when using rename.
(lsp-rename-use-prepare nil))
:custom (;; Fixes type error when using rename.
(lsp-rename-use-prepare nil)
;; Don't override `indent-region' with the server's
;; formatting functionality. Very silly, I think —
;; indentation and formatting are different things.
(lsp-enable-indentation nil))
:config
(syd-defadvice syd-lsp-install-server-a ()
"Override and disbale `lsp-install-server'"
@@ -249,19 +249,21 @@ form."
(defun syd-import-systemd-environment ()
(interactive)
(with-temp-buffer
(shell-command "systemctl --user show-environment" (current-buffer))
(goto-char (point-min))
(while (re-search-forward
(rx bol (group (+ (not "=")))
"="
(or (and "$'" (group (* (not "'"))) "'")
(group (* any)))
eol)
nil t)
(let ((var (match-string 1))
(val (or (match-string 2)
(match-string 3))))
(setenv var val)))))
(let ((blacklist '("TERM")))
(with-temp-buffer
(shell-command "systemctl --user show-environment" (current-buffer))
(goto-char (point-min))
(while (re-search-forward
(rx bol (group (+ (not "=")))
"="
(or (and "$'" (group (* (not "'"))) "'")
(group (* any)))
eol)
nil t)
(let ((var (match-string 1))
(val (or (match-string 2)
(match-string 3))))
(unless (member var blacklist)
(setenv var val)))))))
(provide 'syd/prelude)