From 0fbb1591d88975b8ded860e46459d7914339ea36 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sandro=20J=C3=A4ckel?= Date: Sun, 27 Aug 2023 20:53:45 +0200 Subject: [PATCH 1/2] lsd: 0.23.1 -> 1.0.0, modernise packages, thin out maintainers --- pkgs/tools/misc/lsd/default.nix | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/pkgs/tools/misc/lsd/default.nix b/pkgs/tools/misc/lsd/default.nix index 89f51c0ea5c6..9ae5f69dd055 100644 --- a/pkgs/tools/misc/lsd/default.nix +++ b/pkgs/tools/misc/lsd/default.nix @@ -9,23 +9,26 @@ rustPlatform.buildRustPackage rec { pname = "lsd"; - version = "0.23.1"; + version = "1.0.0"; src = fetchFromGitHub { - owner = "Peltoche"; - repo = pname; - rev = version; - sha256 = "sha256-FY1odcKBl7zJ+MxfohkmC1e45fPQK3MKB3orQdCRpA4="; + owner = "lsd-rs"; + repo = "lsd"; + rev = "v${version}"; + hash = "sha256-syT+1LNdigUWkfJ/wkbY/kny2uW6qfpl7KmW1FjZKR8="; }; - cargoSha256 = "sha256-t7J7hIbLlRq99Yd2/3Zn+PbHhJtaJRdDluDXN0Hp/Jc="; + cargoHash = "sha256-viLr76Bq9OkPMp+BoprQusMDgx59nbevVi4uxjZ+eZg="; nativeBuildInputs = [ installShellFiles pandoc ]; postInstall = '' pandoc --standalone --to man doc/lsd.md -o lsd.1 installManPage lsd.1 - installShellCompletion $releaseDir/build/lsd-*/out/{_lsd,lsd.{bash,fish}} + installShellCompletion --cmd lsd \ + --bash $releaseDir/build/lsd-*/out/lsd.bash \ + --fish $releaseDir/build/lsd-*/out/lsd.fish \ + --zsh $releaseDir/build/lsd-*/out/_lsd ''; # Found argument '--test-threads' which wasn't expected, or isn't valid in this context @@ -36,9 +39,9 @@ rustPlatform.buildRustPackage rec { }; meta = with lib; { - homepage = "https://github.com/Peltoche/lsd"; + homepage = "https://github.com/lsd-rs/lsd"; description = "The next gen ls command"; license = licenses.asl20; - maintainers = with maintainers; [ Br1ght0ne marsam zowoq SuperSandro2000 ]; + maintainers = with maintainers; [ marsam zowoq SuperSandro2000 ]; }; } From 1d96a0fb970c04a91d3fafe471bd4e7f04717350 Mon Sep 17 00:00:00 2001 From: Mario Rodas Date: Tue, 29 Aug 2023 00:00:00 +0000 Subject: [PATCH 2/2] lsd: fix build on darwin --- pkgs/tools/misc/lsd/default.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/pkgs/tools/misc/lsd/default.nix b/pkgs/tools/misc/lsd/default.nix index 9ae5f69dd055..83d7580a7eed 100644 --- a/pkgs/tools/misc/lsd/default.nix +++ b/pkgs/tools/misc/lsd/default.nix @@ -1,7 +1,9 @@ { lib +, stdenv , fetchFromGitHub , rustPlatform , installShellFiles +, darwin , pandoc , testers , lsd @@ -21,6 +23,9 @@ rustPlatform.buildRustPackage rec { cargoHash = "sha256-viLr76Bq9OkPMp+BoprQusMDgx59nbevVi4uxjZ+eZg="; nativeBuildInputs = [ installShellFiles pandoc ]; + + buildInputs = lib.optionals stdenv.isDarwin [ darwin.apple_sdk.frameworks.Security ]; + postInstall = '' pandoc --standalone --to man doc/lsd.md -o lsd.1 installManPage lsd.1