Files
nixpkgs/pkgs/by-name/jo/jotta-cli/package.nix
Dark Steveneq 646b892680
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
push sheeet
2025-10-09 14:15:47 +02:00

47 lines
1.2 KiB
Nix

{
lib,
stdenv,
fetchzip,
nixosTests,
installShellFiles,
}:
stdenv.mkDerivation rec {
pname = "jotta-cli";
version = "0.17.132497";
src = fetchzip {
url = "https://repo.jotta.us/archives/linux/amd64/jotta-cli-${version}_linux_amd64.tar.gz";
hash = "sha256-prhFFjywvffsZKcTIMJfsccA/TYrvpsn/+TpDtIdc98=";
stripRoot = false;
};
nativeBuildInputs = [ installShellFiles ];
installPhase = ''
runHook preInstall
install -Dm0755 usr/bin/jotta-cli usr/bin/jottad -t $out/bin/
runHook postInstall
''
+ lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) ''
installShellCompletion --cmd jotta-cli \
--bash <($out/bin/jotta-cli completion bash) \
--fish <($out/bin/jotta-cli completion fish) \
--zsh <($out/bin/jotta-cli completion zsh)
'';
passthru.tests = { inherit (nixosTests) jotta-cli; };
meta = {
description = "Jottacloud CLI";
homepage = "https://www.jottacloud.com/";
downloadPage = "https://repo.jotta.us/archives/linux/";
maintainers = with lib.maintainers; [ evenbrenden ];
sourceProvenance = with lib.sourceTypes; [ binaryNativeCode ];
license = lib.licenses.unfree;
platforms = [ "x86_64-linux" ];
};
}