dotfiles/hm/vim/git.nix

27 lines
679 B
Nix
Raw Normal View History

2024-01-18 22:49:46 +01:00
{ pkgs, lib, config, ... }:
{
config = {
programs.nixvim = {
extraConfigVim = ''
let g:fugitive_gitlab_domains = [${
lib.strings.concatStringsSep ", " (
map (d: "'${d}'") config.frogeye.vim.fugitive.gitlab_domains
)}]
'';
extraPlugins = with pkgs.vimPlugins; [
fugitive-gitlab-vim # Open files in GitLab
];
plugins = {
fugitive.enable = true; # Git basics
gitsigns.enable = true; # Show changed lines in the gutter
};
};
};
options.frogeye.vim.fugitive = {
gitlab_domains = lib.mkOption {
default = { };
type = lib.types.listOf lib.types.str;
};
};
}