nix-community.nixvim/plugins/by-name/zig/default.nix
Austin Horstman a7012e7864
treewide: originalName -> packPathName
We used to only think of it as the plugin repo's name, but we have been
needing to use it for the name of the plugin's packpath location.
2024-12-13 21:29:00 -06:00

44 lines
797 B
Nix

{
lib,
helpers,
...
}:
with lib;
with helpers.vim-plugin;
mkVimPlugin {
name = "zig";
packPathName = "zig.vim";
package = "zig-vim";
globalPrefix = "zig_";
maintainers = [ maintainers.GaetanLepage ];
# TODO introduced 2024-03-02: remove 2024-05-02
deprecateExtraConfig = true;
imports = [
(mkRenamedOptionModule
[
"plugins"
"zig"
"formatOnSave"
]
[
"plugins"
"zig"
"settings"
"fmt_autosave"
]
)
];
settingsOptions = {
fmt_autosave = helpers.defaultNullOpts.mkFlagInt 1 ''
This plugin enables automatic code formatting on save by default using zig fmt.
To disable it, you can set this option to `0`.
'';
};
settingsExample = {
fmt_autosave = 0;
};
}