From 22674e9b4388cb79fd88a45cb739871d35ec8056 Mon Sep 17 00:00:00 2001 From: Evan Stoll Date: Sat, 11 Jan 2020 13:16:56 -0500 Subject: [PATCH 1/3] broot: fix hardlinks during postPatch phase - add coreutils dependency --- pkgs/tools/misc/broot/default.nix | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/pkgs/tools/misc/broot/default.nix b/pkgs/tools/misc/broot/default.nix index 63d5ff69e79..1391ae5fee5 100644 --- a/pkgs/tools/misc/broot/default.nix +++ b/pkgs/tools/misc/broot/default.nix @@ -1,4 +1,4 @@ -{ stdenv, rustPlatform, fetchFromGitHub }: +{ stdenv, rustPlatform, fetchFromGitHub, coreutils }: rustPlatform.buildRustPackage rec { pname = "broot"; @@ -13,6 +13,10 @@ rustPlatform.buildRustPackage rec { cargoSha256 = "09gnyj97akychin1axp9kcww3c04xx7x1qnplhs2yxfki62r4y2b"; + postPatch = '' + substituteInPlace src/verb_store.rs --replace '"/bin/' '"${coreutils}/bin/' + ''; + meta = with stdenv.lib; { description = "An interactive tree view, a fuzzy search, a balanced BFS descent and customizable commands"; homepage = "https://dystroy.org/broot/"; From 68a5f9f073f36669638aa0bcb43c8a1c76f57935 Mon Sep 17 00:00:00 2001 From: Evan Stoll Date: Sun, 12 Jan 2020 15:53:58 -0500 Subject: [PATCH 2/3] broot: install newly-added shell completions - add installShellFiles dependency --- pkgs/tools/misc/broot/default.nix | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/pkgs/tools/misc/broot/default.nix b/pkgs/tools/misc/broot/default.nix index 1391ae5fee5..b057b6b96aa 100644 --- a/pkgs/tools/misc/broot/default.nix +++ b/pkgs/tools/misc/broot/default.nix @@ -1,4 +1,4 @@ -{ stdenv, rustPlatform, fetchFromGitHub, coreutils }: +{ stdenv, rustPlatform, fetchFromGitHub, coreutils, installShellFiles }: rustPlatform.buildRustPackage rec { pname = "broot"; @@ -13,10 +13,21 @@ rustPlatform.buildRustPackage rec { cargoSha256 = "09gnyj97akychin1axp9kcww3c04xx7x1qnplhs2yxfki62r4y2b"; + nativeBuildInputs = [ installShellFiles ]; + postPatch = '' substituteInPlace src/verb_store.rs --replace '"/bin/' '"${coreutils}/bin/' ''; + postInstall = '' + # install shell completion files + OUT_DIR=target/release/build/broot-*/out + + installShellCompletion --bash $OUT_DIR/{br,broot}.bash + installShellCompletion --fish $OUT_DIR/{br,broot}.fish + installShellCompletion --zsh $OUT_DIR/{_br,_broot} + ''; + meta = with stdenv.lib; { description = "An interactive tree view, a fuzzy search, a balanced BFS descent and customizable commands"; homepage = "https://dystroy.org/broot/"; From ba820a4f770396983f33d8b33f40b14a1f8585c8 Mon Sep 17 00:00:00 2001 From: Evan Stoll Date: Sun, 12 Jan 2020 16:09:43 -0500 Subject: [PATCH 3/3] broot: 0.10.2 -> 0.11.8 --- pkgs/tools/misc/broot/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/tools/misc/broot/default.nix b/pkgs/tools/misc/broot/default.nix index b057b6b96aa..7980298eba1 100644 --- a/pkgs/tools/misc/broot/default.nix +++ b/pkgs/tools/misc/broot/default.nix @@ -2,16 +2,16 @@ rustPlatform.buildRustPackage rec { pname = "broot"; - version = "0.10.2"; + version = "0.11.8"; src = fetchFromGitHub { owner = "Canop"; repo = pname; rev = "v${version}"; - sha256 = "1wisqb4cqdgsnjvmpgxbzs9zcw6npqw1kqxxs8mn33sxlikhbf2l"; + sha256 = "1pbjlfwv4s50s731ryrcc54200g2i04acdxrxk4kpcvi6b19kbky"; }; - cargoSha256 = "09gnyj97akychin1axp9kcww3c04xx7x1qnplhs2yxfki62r4y2b"; + cargoSha256 = "07ncclp4yqqr2lncw4bbcmknm09qzmdcq8iwkhyyfiy3fpyw9hqc"; nativeBuildInputs = [ installShellFiles ];