depot/third_party/nixpkgs/pkgs/tools/misc/zellij/default.nix
Default email f61cd259d4 Project import generated by Copybara.
GitOrigin-RevId: 82155ff501c7622cb2336646bb62f7624261f6d7
2021-10-01 17:20:50 +08:00

52 lines
1.1 KiB
Nix

{ lib
, fetchFromGitHub
, rustPlatform
, stdenv
, installShellFiles
, pkg-config
, libiconv
, openssl
}:
rustPlatform.buildRustPackage rec {
pname = "zellij";
version = "0.18.1";
src = fetchFromGitHub {
owner = "zellij-org";
repo = "zellij";
rev = "v${version}";
sha256 = "sha256-r9RZVmWKJJLiNSbSQPVJPR5koLR6DoAwlitTiQOc1fI=";
};
cargoSha256 = "sha256-xaC9wuT21SYH7H8/d4usDjHeojNZ2d/NkqMqNlQQ1n0=";
nativeBuildInputs = [
installShellFiles
pkg-config
];
buildInputs = [
openssl
] ++ lib.optionals stdenv.isDarwin [
libiconv
];
preCheck = ''
HOME=$TMPDIR
'';
postInstall = ''
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)
'';
meta = with lib; {
description = "A terminal workspace with batteries included";
homepage = "https://zellij.dev/";
license = with licenses; [ mit ];
maintainers = with maintainers; [ therealansh _0x4A6F ];
};
}