Open dwf opened 1 day ago
The issue here is that our lua generation function filters out not just null, but also empty attrs.
This is a horrible behaviour, I know, but it is intended as otherwise many many un-defined options (or their parent attrs) end up in the generated lua.
As a workaround we provide the "empty attr" object, which looks like { __empty = null; }
and can also be used via lib.nixvim.emptyTable
.
In some cases you can also use "raw lua" to achieve the same thing: .__raw = "{ }";
conform-nvim
24.11
Description
After upgrading to nixpkgs and nixvim 24.11, I noticed conform was no longer formatting on save. The
Conform
augroup was completely missing. Looking at the generated init.lua, theformat_on_save
argument was indeed missing despite being not null in my config.I suspect this is a "truthiness" check gone wrong, but there's a lot of indirection in the derivation and I wasn't able to figure it out. The workaround I've used is
format_on_save = { quiet = false; }
which restates the default, but actually successfully generates.Minimal, Reproducible Example (MRE)