by Karrot_Kream · 1y ago · 0 comments
FWIW emacs these days has native LSP support (eglot) and native tree-sitter supported, but you'll need to grab tree-sitter libraries and LSP servers. For MacOS I found just using brew to install most of these works great, and I wonder if Windows can't work the same way. If you're in a VM you should just be able to have your package manager do the work.
LLM support in emacs is still a bit primitive but there are packages like emacs claude-code that are changing things. Personally I wrote an elisp function which grabs the filename of the emacs window relative to the project root and copies it so that I can just paste it into claude code and have it ask questions or do things.
```
(defun copy-buffer-file-name-from-project-root () "Copy the relative path of the buffer in this project to the kill ring" (interactive) (kill-new (file-relative-name (buffer-file-name (current-buffer)) (project-root (project-current)))))
```
if you're curious but depending on how you have your clipboards setup with the kill ring, you may need to modify this.
---
As far as fighting the JS fight on the Zed website, well, I think this thread isn't one of those upvote-anti-JS-rant threads that spring up on this site all the time so shrug.
I usually always make sure everything in my branch is committed before letting Claude Code loose on my code so I can view the changes normally as a magit diff and then choose whether I want to edit any of its changes (90% of the time) or commit as is (10% of the time.) I can also restore files selectively this way and have all of my git tools available if needed.
If you want deep Claude Code integration Cursor style, then check out https://github.com/manzaltu/claude-code-ide.el . The latest releases of emacs support using `vc` blocks to specify packages so you can grab the elisp package straight from the repo and get it working within your emacs.
If you want a chat style interface, GPTel exists but requires some config (not much but not zero either) before it becomes usable as a general chat tool like Claude Desktop or ChatGPT. I'm working on an elisp package to recreate a chat interface atop GPTel and decrease the config burden.
That VM runs a Fedora OS and has vanilla Doom Emacs installed, with a few packages activated in the doom config. So it is about as vanilla doom Emacs as it gets.