blob: a9885fc135181211d1c7b7ff43f180aa301d6d88 (
plain) (
blame)
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
39
40
41
42
43
44
|
{ comma
, fetchFromGitHub
, fzy
, lib
, makeWrapper
, nix
, nix-index
, rustPlatform
, testVersion
}:
rustPlatform.buildRustPackage rec {
pname = "comma";
version = "1.2.3";
src = fetchFromGitHub {
owner = "nix-community";
repo = "comma";
rev = "v${version}";
sha256 = "sha256-emhvBaicLAnu/Kn4oxHngGa5BSxOEwbkhTLO5XvauMw=";
};
cargoSha256 = "sha256-mQxNo4VjW2Q0MYfU+RCb4Ayl9ClpxrSV8X4EKZ7PewA=";
nativeBuildInputs = [ makeWrapper ];
postInstall = ''
wrapProgram $out/bin/comma \
--prefix PATH : ${lib.makeBinPath [ nix fzy nix-index ]}
ln -s $out/bin/comma $out/bin/,
'';
passthru.tests = {
version = testVersion { package = comma; };
};
meta = with lib; {
homepage = "https://github.com/nix-community/comma";
description = "Runs programs without installing them";
license = licenses.mit;
maintainers = with maintainers; [ Enzime artturin ];
platforms = platforms.all;
};
}
|