-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpackage.nix
More file actions
55 lines (48 loc) · 1.01 KB
/
Copy pathpackage.nix
File metadata and controls
55 lines (48 loc) · 1.01 KB
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
45
46
47
48
49
50
51
52
53
54
55
{
lib,
rustPlatform,
makeWrapper,
zellij,
worktrunk,
git,
gh,
openssh,
mosh,
}:
let
manifest = builtins.fromTOML (builtins.readFile ./zigzag/Cargo.toml);
runtimeDependencies = [
zellij
worktrunk
git
gh
openssh
mosh
];
in
rustPlatform.buildRustPackage {
pname = "zigzag";
version = manifest.workspace.package.version;
src = lib.cleanSource ./zigzag;
cargoLock.lockFile = ./zigzag/Cargo.lock;
cargoBuildFlags = [
"--package"
"zigzag-cli"
"--bin"
"zigzag"
];
cargoTestFlags = [ "--workspace" ];
nativeBuildInputs = [ makeWrapper ];
nativeCheckInputs = [ git ];
postInstall = ''
wrapProgram "$out/bin/zigzag" \
--prefix PATH : ${lib.makeBinPath runtimeDependencies}
'';
passthru.runtimeDependencies = runtimeDependencies;
meta = {
description = "Zigzag TUI/CLI project manager for Zellij-based development";
homepage = "https://github.com/arkan/zigzag";
mainProgram = "zigzag";
platforms = lib.platforms.unix;
};
}