From abbbc072b1353d8c8dbc58a6d8f3fdf83a48fa03 Mon Sep 17 00:00:00 2001 From: figsoda Date: Sun, 19 Sep 2021 11:53:47 -0400 Subject: [PATCH] cargo-tally: init at 1.0.0 --- .../tools/rust/cargo-tally/default.nix | 26 +++++++++++++++++++ pkgs/top-level/all-packages.nix | 3 +++ 2 files changed, 29 insertions(+) create mode 100644 pkgs/development/tools/rust/cargo-tally/default.nix diff --git a/pkgs/development/tools/rust/cargo-tally/default.nix b/pkgs/development/tools/rust/cargo-tally/default.nix new file mode 100644 index 000000000000..21a5b470a2e9 --- /dev/null +++ b/pkgs/development/tools/rust/cargo-tally/default.nix @@ -0,0 +1,26 @@ +{ lib, rustPlatform, fetchCrate, stdenv, DiskArbitration, Foundation, IOKit }: + +rustPlatform.buildRustPackage rec { + pname = "cargo-tally"; + version = "1.0.0"; + + src = fetchCrate { + inherit pname version; + sha256 = "16r60ddrqsss5nagfb5g49md8wwm4zbp9sffbm23bhlqhxh35y0i"; + }; + + cargoSha256 = "0ffq67vy0pa7va8j93g03bralz7lck6ds1hidbpzzkp13pdcgf97"; + + buildInputs = lib.optionals stdenv.isDarwin [ + DiskArbitration + Foundation + IOKit + ]; + + meta = with lib; { + description = "Graph the number of crates that depend on your crate over time"; + homepage = "https://github.com/dtolnay/cargo-tally"; + license = with licenses; [ asl20 /* or */ mit ]; + maintainers = with maintainers; [ figsoda ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index bb1330550ecd..0bc01a693405 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -12433,6 +12433,9 @@ with pkgs; cargo-spellcheck = callPackage ../development/tools/rust/cargo-spellcheck { }; cargo-sweep = callPackage ../development/tools/rust/cargo-sweep { }; cargo-sync-readme = callPackage ../development/tools/rust/cargo-sync-readme {}; + cargo-tally = callPackage ../development/tools/rust/cargo-tally { + inherit (darwin.apple_sdk.frameworks) DiskArbitration Foundation IOKit; + }; cargo-udeps = callPackage ../development/tools/rust/cargo-udeps { inherit (darwin.apple_sdk.frameworks) CoreServices Security SystemConfiguration; };