mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-26 07:34:11 +00:00
aa745c9b73
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
67 lines
1.4 KiB
Nix
67 lines
1.4 KiB
Nix
{ lib
|
|
, fetchFromGitHub
|
|
, rustPlatform
|
|
, stdenv
|
|
, installShellFiles
|
|
, pkg-config
|
|
, libiconv
|
|
, openssl
|
|
, DiskArbitration
|
|
, Foundation
|
|
, mandown
|
|
, zellij
|
|
, testers
|
|
}:
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
pname = "zellij";
|
|
version = "0.35.2";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "zellij-org";
|
|
repo = "zellij";
|
|
rev = "v${version}";
|
|
sha256 = "sha256-2wgv84Qm/X5mcEcM5ch7tFHZVg/xassUOtssSzbr0fs=";
|
|
};
|
|
|
|
cargoSha256 = "sha256-GAPzWmFUtLWlcDAGHhEowvjM/OKRUuuD/0aa1tbmKuI=";
|
|
|
|
nativeBuildInputs = [
|
|
mandown
|
|
installShellFiles
|
|
pkg-config
|
|
];
|
|
|
|
buildInputs = [
|
|
openssl
|
|
] ++ lib.optionals stdenv.isDarwin [
|
|
libiconv
|
|
DiskArbitration
|
|
Foundation
|
|
];
|
|
|
|
preCheck = ''
|
|
HOME=$TMPDIR
|
|
'';
|
|
|
|
postInstall = ''
|
|
mandown docs/MANPAGE.md > zellij.1
|
|
installManPage zellij.1
|
|
|
|
installShellCompletion --cmd $pname \
|
|
--bash <($out/bin/zellij setup --generate-completion bash) \
|
|
--fish <($out/bin/zellij setup --generate-completion fish) \
|
|
--zsh <($out/bin/zellij setup --generate-completion zsh)
|
|
'';
|
|
|
|
passthru.tests.version = testers.testVersion { package = zellij; };
|
|
|
|
meta = with lib; {
|
|
description = "A terminal workspace with batteries included";
|
|
homepage = "https://zellij.dev/";
|
|
changelog = "https://github.com/zellij-org/zellij/blob/v${version}/CHANGELOG.md";
|
|
license = with licenses; [ mit ];
|
|
maintainers = with maintainers; [ therealansh _0x4A6F abbe thehedgeh0g ];
|
|
};
|
|
}
|