at 23.05-pre 42 lines 1.3 kB view raw
1{ lib, stdenv, rustPlatform, fetchCrate, installShellFiles 2, libgpg-error, gpgme, gettext, openssl, Security 3}: 4 5rustPlatform.buildRustPackage rec { 6 pname = "sheesy-cli"; 7 version = "4.0.11"; 8 9 src = fetchCrate { 10 inherit version pname; 11 sha256 = "1l21ji9zqy8x1g2gvqwdhya505max07ibx1hh88s36k0jbvdb7xc"; 12 }; 13 14 cargoSha256 = "159a5ph1gxwcgahyr8885lq3c1w76nxzfrfdpyqixqrr7jzx2rd3"; 15 cargoDepsName = pname; 16 17 nativeBuildInputs = [ libgpg-error gpgme gettext installShellFiles ]; 18 19 buildInputs = [ openssl ] ++ lib.optionals stdenv.isDarwin [ Security ]; 20 21 buildFeatures = [ "vault" "extract" "completions" "substitute" "process" ]; 22 23 checkFeatures = [ ]; 24 25 cargoBuildFlags = [ "--bin" "sy" ]; 26 27 postInstall = '' 28 installShellCompletion --cmd sy \ 29 --bash <($out/bin/sy completions bash) \ 30 --fish <($out/bin/sy completions fish) \ 31 --zsh <($out/bin/sy completions zsh) 32 ''; 33 34 meta = with lib; { 35 description = "The 'share-secrets-safely' CLI to interact with GPG/pass-like vaults"; 36 homepage = "https://share-secrets-safely.github.io/cli/"; 37 changelog = "https://github.com/share-secrets-safely/cli/releases/tag/${version}"; 38 license = with licenses; [ lgpl21Only ]; 39 maintainers = with maintainers; [ devhell ]; 40 mainProgram = "sy"; 41 }; 42}