2023-05-25 14:41:09 +00:00
|
|
|
{ lib, stdenv, rustPlatform, fetchFromGitHub, installShellFiles }:
|
2023-05-14 08:35:37 +00:00
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "jf";
|
2023-05-25 14:41:09 +00:00
|
|
|
version = "0.3.3";
|
2023-05-14 08:35:37 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "sayanarijit";
|
|
|
|
repo = "jf";
|
|
|
|
rev = "v${version}";
|
2023-05-25 14:41:09 +00:00
|
|
|
hash = "sha256-dZX8C/nJaKfgHsUAXR1DRZS+PWDZF+QDVpOSaOlwFp4=";
|
2023-05-14 08:35:37 +00:00
|
|
|
};
|
|
|
|
|
2023-05-25 14:41:09 +00:00
|
|
|
cargoHash = "sha256-H9UZCKy+0xL6J8f/6yCiM4X5TMOrN8UEEDwxqNR7xQY=";
|
|
|
|
|
|
|
|
nativeBuildInputs = [ installShellFiles ];
|
|
|
|
|
|
|
|
# skip auto manpage update
|
|
|
|
buildNoDefaultFeatures = true;
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
installManPage assets/jf.1
|
|
|
|
'';
|
2023-05-14 08:35:37 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "A small utility to safely format and print JSON objects in the commandline";
|
|
|
|
homepage = "https://github.com/sayanarijit/jf";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = [ maintainers.sayanarijit ];
|
|
|
|
};
|
|
|
|
}
|