summary refs log tree commit diff
path: root/pkgs/development/tools/rust/cargo-wipe/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/development/tools/rust/cargo-wipe/default.nix')
-rw-r--r--pkgs/development/tools/rust/cargo-wipe/default.nix32
1 files changed, 32 insertions, 0 deletions
diff --git a/pkgs/development/tools/rust/cargo-wipe/default.nix b/pkgs/development/tools/rust/cargo-wipe/default.nix
new file mode 100644
index 00000000000..a59a124317b
--- /dev/null
+++ b/pkgs/development/tools/rust/cargo-wipe/default.nix
@@ -0,0 +1,32 @@
+{ lib
+, rustPlatform
+, fetchFromGitHub
+, nix-update-script
+}:
+
+rustPlatform.buildRustPackage rec {
+  pname = "cargo-wipe";
+  version = "0.3.1";
+
+  src = fetchFromGitHub {
+    owner = "mihai-dinculescu";
+    repo = "cargo-wipe";
+    rev = "v${version}";
+    sha256 = "sha256-sVekfGHg2wspP5/zJzXTXupspwJr4hQBucY5+8iUjUQ=";
+  };
+
+  cargoSha256 = "sha256-EoXgsWg1Rh7C+fIqvefkLdck4Yj3kox2ZAU3kn6nH8Q=";
+
+  passthru = {
+    updateScript = nix-update-script {
+      attrPath = pname;
+    };
+  };
+
+  meta = with lib; {
+    description = ''Cargo subcommand "wipe": recursively finds and optionally wipes all "target" or "node_modules" folders'';
+    homepage = "https://github.com/mihai-dinculescu/cargo-wipe";
+    license = with licenses; [ mit ];
+    maintainers = with maintainers; [ otavio ];
+  };
+}