neovim-flake/modules/plugins/utility/wakatime/config.nix

23 lines
428 B
Nix
Raw Normal View History

2023-05-10 13:41:17 +02:00
{
config,
2023-05-10 13:56:49 +02:00
pkgs,
lib,
2023-05-10 13:41:17 +02:00
...
}: let
2024-03-24 01:14:39 +01:00
inherit (lib.modules) mkIf;
inherit (lib.meta) getExe;
2023-05-10 13:41:17 +02:00
cfg = config.vim.utility.vim-wakatime;
in {
config = mkIf cfg.enable {
vim = {
startPlugins = [pkgs.vimPlugins.vim-wakatime];
# Wakatime configuration is stored as vim globals.
globals = {
"wakatime_CLIPath" = mkIf (cfg.cli-package != null) "${getExe cfg.cli-package}";
};
};
2023-05-10 13:41:17 +02:00
};
}