summary refs log tree commit diff
path: root/pkgs/development/tools/rust/cargo-limit/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/development/tools/rust/cargo-limit/default.nix')
-rw-r--r--pkgs/development/tools/rust/cargo-limit/default.nix36
1 files changed, 36 insertions, 0 deletions
diff --git a/pkgs/development/tools/rust/cargo-limit/default.nix b/pkgs/development/tools/rust/cargo-limit/default.nix
new file mode 100644
index 00000000000..76f766685ab
--- /dev/null
+++ b/pkgs/development/tools/rust/cargo-limit/default.nix
@@ -0,0 +1,36 @@
+{ lib
+, rustPlatform
+, fetchFromGitHub
+, nix-update-script
+, stdenv
+, libiconv
+}:
+
+rustPlatform.buildRustPackage rec {
+  pname = "cargo-limit";
+  version = "0.0.8";
+
+  src = fetchFromGitHub {
+    owner = "alopatindev";
+    repo = "cargo-limit";
+    rev = version;
+    sha256 = "sha256-OHBxQcXhZkJ1F6xLc7/sPpJhJzuJXb91IUjAtyC3XP8=";
+  };
+
+  cargoSha256 = "sha256-LxqxRtMKUKZeuvk1caoYy8rv1bkEOQBM8i5SXMF4GXc=";
+
+  buildInputs = lib.optionals stdenv.isDarwin [ libiconv ];
+
+  passthru = {
+    updateScript = nix-update-script {
+      attrPath = pname;
+    };
+  };
+
+  meta = with lib; {
+    description = "Cargo subcommand \"limit\": reduces the noise of compiler messages";
+    homepage = "https://github.com/alopatindev/cargo-limit";
+    license = with licenses; [ asl20 /* or */ mit ];
+    maintainers = with maintainers; [ otavio ];
+  };
+}