spacemacs

Spacemacs docs: http://develop.spacemacs.org/doc/DOCUMENTATION.html http://develop.spacemacs.org/layers/+lang/clojure/README.html https://practicalli.github.io/spacemacs/
cjsauer 2021-04-02T15:15:48.056700Z

Has anyone encountered the lsp layer being too aggressive, prompting if I “want to watch all files” in some project that I don’t even have open right now? It’s also not part of my treemacs workspace. I’m pulling my hair out trying to stop lsp from even looking at directories that I’m uninterested in on startup.

practicalli-john 2021-04-02T15:18:15.056800Z

I found LSP very aggressive by default. Took me a while to figure how to tone it down and just give me a few useful things. It's still a bit too invasive for me, but has a few things missing from cider

practicalli-john 2021-04-02T15:20:02.056900Z

LSP will trigger when ever a file is open for a project. I used to have lots of layouts, one for each project, that really complicates things with LSP.

practicalli-john 2021-04-02T15:23:02.057Z

I need to figure out how to just use LSP when I want it there. I haven't found out how to switch it off when it's already running without disabling LSP completely and restarting Emacs

cjsauer 2021-04-02T15:30:03.058300Z

That’s what I’ve found as well. It seems to “latch on” to projects that I’ve opened once in the past. Now I want to work on project X and LSP keeps starting up for the project that I’m not interested in anymore. I’m looking everywhere for some kind of LSP project list/cache/recent files etc to no avail…

cjsauer 2021-04-02T15:31:36.058600Z

Ooh…`lsp-workspace-folders-remove` seems close

practicalli-john 2021-04-02T15:32:07.058700Z

That does sound useful. Let me know what works

cjsauer 2021-04-02T15:37:35.060200Z

Playing around. That almost seemed to work. It no longer prompts to “watch all files” for that project after I used lsp-workspace-folders-remove on it, and then restarted emacs. However, now I keep getting the file is not part of any project. Selection action: prompt for the file from that removed project that I don’t have open anywhere….frustrating…

cjsauer 2021-04-02T15:37:46.060500Z

LSP must keep some kind of permanent file list of everything you touch

cjsauer 2021-04-02T16:26:31.061500Z

I think the issue is that spacemacs is saving/restoring all the buffers even on exit, and LSP is scanning those buffers for potential targets. Is it possible to prevent emacs from restoring buffers from previous sessions? Tried (desktop-save-mode -1) in my user-config to no avail…

cjsauer 2021-04-02T16:28:42.061800Z

Might be related to layouts…not sure…I don’t personally use layouts at all

practicalli-john 2021-04-02T17:49:12.062Z

I do want Spacemacs to remember buffers and project, that is why I use layouts. Layouts are more important to me than LSP as I regularly work on multiple projects. It's another reason I have struggled to adopt LSP myself.

ericdallo 2021-04-02T18:16:21.062100Z

You can just disable file watchers with lsp-enable-file-watchers nil https://emacs-lsp.github.io/lsp-mode/page/performance/#ignore-watch-foldersfiles

ericdallo 2021-04-02T18:46:36.062500Z

lsp-modeline--enable-diagnostics is still wrong on docs, it should be lsp-modeline-diagnostics-enable