conjure icon indicating copy to clipboard operation
conjure copied to clipboard

Include vendored nfnl fennel code in addition to lua

Open garrett-hopper opened this issue 7 months ago • 5 comments

Currently only the compiled lua version of nfnl is included in the repo for the conjure.nfnl module.

It'd be nice if the actual fennel version of nfnl was included to get proper completion out of fennel-ls.

garrett-hopper avatar May 23 '25 20:05 garrett-hopper

I think this may be less of an issue with the latest unreleased version of fennel-ls. Hoping that gets pushed to luarocks sometime. The completion system appears to have been rewritten, and I believe I can simply add nfnl to the search path then? (Though you'd still have to do something about the nfnl -> conjure.nfnl 🤔)

garrett-hopper avatar May 23 '25 20:05 garrett-hopper

Oh this is really interesting. I would quite like to avoid embedding it if possible, but I see the appeal. Leave this with me for a little bit. I suppose copying over all .fnl and .lua files would simplify my embedding script, it would no longer need to selectively embed macro files which is a bit fiddly.

We could just copy the file trees over and do the find and replace without having to do any clever grepping on the .fnl.

Olical avatar May 26 '25 20:05 Olical

Yeah, no rush, happy with whatever you decide is more maintainable. I know having the source fnl files in two places isn't ideal. Possibly worth a git submodule or something, but that's kinda a pain. 🤷

garrett-hopper avatar May 26 '25 20:05 garrett-hopper

Could you share how I might replicate what you're experiencing?

I think this may be less of an issue with the latest unreleased version of fennel-ls

  • Are you saying that the latest unreleased version (what commit is it?) of fennel-ls doesn't have the problem?
  • What version (commit, package, etc.) of fennel_ls are you using?
  • If you have a flsproject.fnl file for your Fennel project, have you tried adding the path to an nfnl installation to the :fennel-path entry in it?

russtoku avatar Aug 23 '25 23:08 russtoku

I've forgotten a lot of context on this issue. Haven't been actively using much fennel lately. I do see that fennel-ls has been updated on luarocks since. (Prior to that, I would've been using 0.1.3-4 which had the issue. No idea if the new version does truly resolve the issue with completions when nfnl is vendored or not though. Feel free to close; I don't have time to verify now, but I believe it can be worked around now.

garrett-hopper avatar Aug 24 '25 01:08 garrett-hopper