Skip to content

Conversation

@atomicptr
Copy link
Owner

@atomicptr atomicptr commented Nov 30, 2025

This is an experiment to replace Babashka with more Lua (and some Rust)

I initially implemented stuff in Babashka because you can't do a lot of stuff in Neovims lua and this seemed like a great idea, however this kinda got me into implementing most logic in Clojure because I wanted to limit how much calling between both worlds we do with the custom RPC stuff.

This however has some disadvantages, one is in order to ship this with only Babashka I can't use dependencies because while Babashka ships with a ton if you need anything else the user has to have a JDK available which I don't like also maybe Clojure isn't something most Neovim and Defold users are familar with so this might make this plugin less approachable. While this is also true for Rust to a somewhat lesser degree (I think) the new approach I am playing around with here is to only move what we can't do with Neovim Lua by default to the sidecar and everything else should stay in Lua, e.g. Neovim Lua doesn't have a HTTP client so we do the editor command API via Rust. The goal being to completely remove any dependencies outside Neovim and the sidecar itself

Things to port

  • send command
  • list commands
  • set default editor (modifying Defolds config)
  • installing & managing dependencies
  • installing & managing neovide (if necessary)
  • launch neovim / neovide
  • focus handler for neovim & game
  • installing & managing mobdap

Other tasks

  • handle sidecar installation, some package managers can apparently install these automatically e.g. blink.cmp has this with LazyVim, otherwise we probably need to download the sidecar from Github
  • add tests for sidecar
  • add sidecar builds to pipeline

@atomicptr atomicptr changed the title Draft: Add sidecar to do things Neovim Lua can't do Draft: Replace Babashka with Lua + Sidecar library Nov 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants