3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/shells/zsh/zsh-powerlevel10k/default.nix
2020-07-06 19:48:10 +02:00

40 lines
1.2 KiB
Nix

{ stdenv, fetchFromGitHub, substituteAll, pkgs }:
# To make use of this derivation, use
# `programs.zsh.promptInit = "source ${pkgs.zsh-powerlevel10k}/share/zsh-powerlevel10k/powerlevel10k.zsh-theme";`
stdenv.mkDerivation rec {
pname = "powerlevel10k";
version = "1.12.0";
src = fetchFromGitHub {
owner = "romkatv";
repo = "powerlevel10k";
rev = "v${version}";
sha256 = "08zg4in70h3kray6lazszzy26gvil9w2cr6xmkbgjsv3k6w3k0jg";
};
patches = [
(substituteAll {
src = ./gitstatusd.patch;
gitstatusdPath = "${pkgs.gitAndTools.gitstatus}/bin/gitstatusd";
})
];
installPhase = ''
install -D powerlevel10k.zsh-theme --target-directory=$out/share/zsh-powerlevel10k
install -D config/* --target-directory=$out/share/zsh-powerlevel10k/config
install -D internal/* --target-directory=$out/share/zsh-powerlevel10k/internal
cp -R gitstatus $out/share/zsh-powerlevel10k/gitstatus
'';
meta = {
description = "A fast reimplementation of Powerlevel9k ZSH theme";
homepage = "https://github.com/romkatv/powerlevel10k";
license = stdenv.lib.licenses.mit;
platforms = stdenv.lib.platforms.unix;
maintainers = [ stdenv.lib.maintainers.hexa ];
};
}