feat(modules): add support for lazygit

This commit is contained in:
isabel 2023-06-19 16:14:19 +01:00 committed by Sam Nystrom
parent 1e95e1c7bc
commit 547ba1984c
2 changed files with 22 additions and 0 deletions

View file

@ -11,6 +11,7 @@ in
./bottom.nix ./bottom.nix
./btop.nix ./btop.nix
./kitty.nix ./kitty.nix
./lazygit.nix
./starship.nix ./starship.nix
./helix.nix ./helix.nix
./gtk.nix ./gtk.nix

View file

@ -0,0 +1,21 @@
{ config, pkgs, lib, ... }:
let cfg = config.programs.lazygit.catppuccin;
in {
options.programs.lazygit.catppuccin =
lib.ctp.mkCatppuccinOpt "lazygit" config;
config.programs.lazygit.settings = with builtins;
with lib;
with pkgs;
let
file = fetchFromGitHub
{
owner = "catppuccin";
repo = "lazygit";
rev = "f01edfd57fa2aa7cd69a92537a613bb3c91e65dd";
sha256 = "sha256-zjzDtXcGtUon4QbrZnlAPzngEyH56yy8TCyFv0rIbOA=";
} + "/themes/${cfg.flavour}.yml";
in
mkIf cfg.enable (ctp.fromYaml pkgs file);
}