ripasso-cursive: cosmetic changes (#361736)
[NixPkgs.git] / pkgs / by-name / se / sequoia-sqop / package.nix
blobff62b5793f0e5589a51ca64ec093681b7961ca2a
1 { lib
2 , fetchFromGitLab
3 , nettle
4 , nix-update-script
5 , installShellFiles
6 , rustPlatform
7 , pkg-config
8 }:
10 rustPlatform.buildRustPackage rec {
11   pname = "sequoia-sqop";
12   version = "0.35.0";
14   src = fetchFromGitLab {
15     owner = "sequoia-pgp";
16     # From some reason the repository is not sequoia-sqop - like the command
17     # generated etc
18     repo = "sequoia-sop";
19     rev = "v${version}";
20     hash = "sha256-JgLozj9LZwk6TRHj2d4kiq8j3aILBUWaE9ldzvlTBNs=";
21   };
23   cargoHash = "sha256-Z0UqJRm4QepMl83zE1TI7g/pc7b9XxUWeaMVVrp0zZ8=";
25   nativeBuildInputs = [
26     pkg-config
27     rustPlatform.bindgenHook
28     installShellFiles
29   ];
31   buildInputs = [
32     nettle
33   ];
34   buildFeatures = [ "cli" ];
36   # Install manual pages
37   postInstall = ''
38     mkdir -p $out/share/man
39     cp -r man-sqop $out/share/man/man1
40     installShellCompletion --cmd sqop \
41       --bash target/*/release/build/sequoia-sop*/out/sqop.bash \
42       --fish target/*/release/build/sequoia-sop*/out/sqop.fish \
43       --zsh target/*/release/build/sequoia-sop*/out/_sqop
44     # Also elv and powershell are generated there
45   '';
47   doCheck = true;
49   passthru.updateScript = nix-update-script { };
51   meta = {
52     description = "Implementation of the Stateless OpenPGP Command Line Interface using Sequoia";
53     homepage = "https://docs.sequoia-pgp.org/sqop/";
54     license = lib.licenses.gpl2Plus;
55     maintainers = with lib.maintainers; [ doronbehar ];
56     mainProgram = "sqop";
57   };