2021-02-05 17:12:51 +00:00
|
|
|
{ lib
|
2021-12-19 01:06:50 +00:00
|
|
|
, stdenv
|
2021-12-06 16:07:01 +00:00
|
|
|
, fetchFromGitHub
|
2021-12-19 01:06:50 +00:00
|
|
|
, rustPlatform
|
|
|
|
, Security
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
2021-12-19 01:06:50 +00:00
|
|
|
rustPlatform.buildRustPackage rec {
|
2020-04-24 23:36:52 +00:00
|
|
|
pname = "jsonwatch";
|
2021-12-19 01:06:50 +00:00
|
|
|
version = "0.6.0";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-12-06 16:07:01 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "dbohdan";
|
2021-12-19 01:06:50 +00:00
|
|
|
repo = pname;
|
2021-12-06 16:07:01 +00:00
|
|
|
rev = "v${version}";
|
2021-12-19 01:06:50 +00:00
|
|
|
sha256 = "sha256-TGW04P8t0mAXza7I7qp6QRXA/MDE3m1dlRC7bMf2dSk=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-12-19 01:06:50 +00:00
|
|
|
cargoSha256 = "sha256-Gjb7v3kz11iOml3Ykxhy43KNxzaprgMbb5DpPNChLTc=";
|
|
|
|
|
|
|
|
buildInputs = lib.optional stdenv.isDarwin [
|
|
|
|
Security
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Like watch -d but for JSON";
|
|
|
|
longDescription = ''
|
|
|
|
jsonwatch is a command line utility with which you can track
|
|
|
|
changes in JSON data delivered by a shell command or a web
|
2021-12-19 01:06:50 +00:00
|
|
|
(HTTP/HTTPS) API. jsonwatch requests data from the designated
|
2020-04-24 23:36:52 +00:00
|
|
|
source repeatedly at a set interval and displays the
|
2021-12-19 01:06:50 +00:00
|
|
|
differences when the data changes.
|
2020-04-24 23:36:52 +00:00
|
|
|
'';
|
|
|
|
homepage = "https://github.com/dbohdan/jsonwatch";
|
|
|
|
license = licenses.mit;
|
2021-12-19 01:06:50 +00:00
|
|
|
maintainers = with maintainers; [ fab ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|