Fork me on GitHub
#lsp
<
2022-11-27
>
Martynas Maciulevičius09:11:40

Hey. Do you think that 9: Create test for 'hi' should also create the test file itself if it doesn't exist? It doesn't create the file if it doesn't exist but yes, it adds the test itself to the file :thinking_face:

2
Carlo11:11:27

Which command is actually called to create a new test?

Carlo11:11:33

Thank you! TIL!

Martynas Maciulevičius11:11:44

Actually it should create the test file as the logic is there but for some reason it doesn't do that for me 😕 https://github.com/clojure-lsp/clojure-lsp/blob/7a23bac09cafad80c7e82fcdac7cb7558a15fe79/lib/src/clojure_lsp/refactor/transform.clj#L880

Martynas Maciulevičius11:11:14

I think that the nature of the code in that link means that it's my nvim that doesn't display that unsaved file that LSP server marks as edited :thinking_face: So there is an imaginary file but it's not saved into hard drive and therefore it's not registered that it exists :thinking_face:

ericdallo13:11:10

Makes sense, sounds like a bug on nvim, clojure-lsp already returns an edit saying that there is a new document, the editor should create a buffer with that( not necessarily save the buffer file on disk) but create and display to user

Martynas Maciulevičius17:11:05

It could also be an error in my FZF config as it lists files in git repo only (this is what I configured). And NvimTree lists only files on disk (I think). Probably these could be the problems :thinking_face:

👍 1
Martynas Maciulevičius20:11:31

I created this one: https://github.com/neovim/nvim-lspconfig/issues/2261 The buffer doesn't show up in :ls menu either.