nixos-configs/common/overlays/dracula-theme/git.nix
matt1432 9f2b537bf7
All checks were successful
Discord / discord commits (push) Has been skipped
refactor: use non-flake inputs instead of fetchers
2023-12-31 15:44:53 -05:00

23 lines
408 B
Nix

{
stdenv,
git-theme-src,
...
}:
stdenv.mkDerivation {
name = "dracula-git";
version = git-theme-src.rev;
src = git-theme-src;
installPhase = ''
# Git colors
cp -a ./config/gitconfig ./git-colors
chmod 777 ./git-colors
line=$(grep -n 'Dracula Dark Theme' ./git-colors | cut -d: -f1)
sed -i "1,$((line-1))d" ./git-colors
mkdir $out
cp -a ./git-colors $out
'';
}