catppuccin/emacs

rustic and eglot failure with catppuccin theme

Closed this issue · 3 comments

this particular error: rustic/:catch: Symbol’s function definition is void: catppuccin-quantize-color is causing issues with eglot on rustic mode to fail, and instead tries to install lsp-mode, but this happens only in emacsclient.
Howerver this works fine if emacs is started as a separate instance and rustic starts up eglot correctly

(use-package catppuccin-theme
  :demand t
  :init
  (setq catppuccin-flavor 'mocha) ;; or 'latte, 'macchiato, or 'mocha
  (load-theme 'catppuccin)
  (add-hook 'server-after-make-frame-hook #'catppuccin-reload)
  )
(use-package rust-mode
  :demand t
  :init
  (setq rust-mode-treesitter-derive t))

(use-package rustic
  :after (rust-mode)
  :demand t
  :config
  (setq lsp-enable-symbol-highlighting nil)
  (setq lsp-signature-auto-activate nil)
  ;; eglot mode
  (setq rustic-lsp-client 'eglot)
  )
jtbx commented

That's really weird it's not working in emacsclient. The problem is that some library is trying to call an internal theme function (catppuccin-quantize-color), and this function is unbound at the end of the theme.

(fmakunbound 'catppuccin-quantize-color)

I've opened #188 to remove these calls, would you be able to test out that branch and let me know if that works for you?

That's really weird it's not working in emacsclient. The problem is that some library is trying to call an internal theme function (catppuccin-quantize-color), and this function is unbound at the end of the theme.

(fmakunbound 'catppuccin-quantize-color)

I've opened #188 to remove these calls, would you be able to test out that branch and let me know if that works for you?

Hopefully if I am pulling down the package correctly

(use-package catppuccin-theme                                                                                                                                                      
	     :ensure (:host github :repo "catppuccin/emacs" :branch "internal")                                                                                                               
	     :init                                                                                                                                                                            
	     (setq catppuccin-flavor 'mocha) ;; or 'latte, 'macchiato, or 'mocha                                                                                                              
	     (load-theme 'catppuccin)                                                                                                                                                         
	     (add-hook 'server-after-make-frame-hook #'catppuccin-reload)                                                                                                                     
	     )  

the error message seems to be resolved and eglot is called properly

jtbx commented

Awesome thanks. ❤️