2021-01-15 22:18:51 +00:00
|
|
|
{ lib, stdenv, fetchFromGitHub, rustPlatform, Security, fetchpatch }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "jwt-cli";
|
2021-02-22 21:28:39 +00:00
|
|
|
version = "4.0.0";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "mike-engel";
|
|
|
|
repo = pname;
|
|
|
|
rev = version;
|
2021-02-22 21:28:39 +00:00
|
|
|
sha256 = "sha256-82Le0kdt/fnSQwsRRYHy4Jv9rsCPGf5dIWmoZE2cPxY=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-02-22 21:28:39 +00:00
|
|
|
cargoSha256 = "sha256-nk4nrsePiUirVPoOPehCOf5ZoGVj3jy7PnSZENnpcaM=";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
buildInputs = lib.optional stdenv.isDarwin Security;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2020-09-25 04:45:31 +00:00
|
|
|
doInstallCheck = true;
|
|
|
|
installCheckPhase = "$out/bin/jwt --version";
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Super fast CLI tool to decode and encode JWTs";
|
|
|
|
homepage = "https://github.com/mike-engel/jwt-cli";
|
|
|
|
license = with licenses; [ mit ];
|
|
|
|
maintainers = with maintainers; [ rycee ];
|
|
|
|
};
|
|
|
|
}
|