-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdefault.nix
More file actions
38 lines (34 loc) · 722 Bytes
/
Copy pathdefault.nix
File metadata and controls
38 lines (34 loc) · 722 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
{
fetchurl,
lib,
stdenvNoCC,
selfSource,
...
}:
let
inherit (selfSource) version;
source = lib.findFirst (
entry: entry.hashType == "sha256" && lib.hasInfix "/${version}/" entry.url
) null selfSource.hashes;
in
assert source != null;
stdenvNoCC.mkDerivation {
pname = "homebrew-zsh-completion";
inherit version;
src = fetchurl {
inherit (source) url;
inherit (source) hash;
};
dontUnpack = true;
installPhase = ''
mkdir $out/
cp -r $src $out/_brew
chmod +x $out/_brew
'';
meta = with lib; {
description = "Homebrew zsh completion script";
homepage = "https://github.com/Homebrew/brew";
license = licenses.bsd2;
platforms = platforms.unix;
};
}