1 { stdenvNoCC, lib, fetchFromGitHub, installShellFiles }:
3 stdenvNoCC.mkDerivation rec {
6 src = fetchFromGitHub {
7 owner = "zdharma-continuum";
10 hash = "sha256-fnBV0LmC/wJm0pOITJ1mhiBqsg2F8AQJWvn0p/Bgo5Q=";
12 # adapted from https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=zsh-zplugin-git
15 nativeBuildInputs = [ installShellFiles ];
17 outdir="$out/share/$pname"
21 # Zplugin's source files
22 install -dm0755 "$outdir"
23 # Installing backward compatibility layer
24 install -m0644 zinit{,-side,-install,-autoload}.zsh "$outdir"
25 install -m0755 share/git-process-output.zsh "$outdir"
27 # Zplugin autocompletion
28 installShellCompletion --zsh _zinit
30 #TODO:Zplugin-module files
31 # find zmodules/ -type d -exec install -dm 755 "{}" "$outdir/{}" \;
32 # find zmodules/ -type f -exec install -m 744 "{}" "$outdir/{}" \;
38 homepage = "https://github.com/zdharma-continuum/zinit";
39 description = "Flexible zsh plugin manager";
40 license = licenses.mit;
41 maintainers = with maintainers; [ pasqui23 sei40kr ];