From 01bf973fc47209ab32f32a9b8b9e8c394c1f8990 Mon Sep 17 00:00:00 2001 From: Piotr Kwiecinski <2151333+piotrkwiecinski@users.noreply.github.com> Date: Sun, 4 Aug 2024 10:58:03 +0200 Subject: [PATCH 1/2] castor: fix build This fixes the generation of bash completion by patching the shebang of the castor script before the generation is excuted. --- pkgs/development/php-packages/castor/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/development/php-packages/castor/default.nix b/pkgs/development/php-packages/castor/default.nix index c191d7978cd74..cd17a74742836 100644 --- a/pkgs/development/php-packages/castor/default.nix +++ b/pkgs/development/php-packages/castor/default.nix @@ -35,9 +35,9 @@ php.buildComposerProject (finalAttrs: { # install shell completions postInstall = '' installShellCompletion --cmd castor \ - --bash <($out/bin/castor completion bash) \ - --fish <($out/bin/castor completion fish) \ - --zsh <($out/bin/castor completion zsh) + --bash <(php $out/bin/castor completion bash) \ + --fish <(php $out/bin/castor completion fish) \ + --zsh <(php $out/bin/castor completion zsh) ''; passthru = { From ed0930b7b039b8c103060c3adee3910ff4b26f60 Mon Sep 17 00:00:00 2001 From: Piotr Kwiecinski <2151333+piotrkwiecinski@users.noreply.github.com> Date: Sun, 4 Aug 2024 11:01:50 +0200 Subject: [PATCH 2/2] castor: 0.14.0 -> 0.17.1 --- pkgs/development/php-packages/castor/default.nix | 16 +++------------- 1 file changed, 3 insertions(+), 13 deletions(-) diff --git a/pkgs/development/php-packages/castor/default.nix b/pkgs/development/php-packages/castor/default.nix index cd17a74742836..04b45a5961de8 100644 --- a/pkgs/development/php-packages/castor/default.nix +++ b/pkgs/development/php-packages/castor/default.nix @@ -1,7 +1,6 @@ { lib, fetchFromGitHub, - fetchpatch, installShellFiles, php, nix-update-script, @@ -10,25 +9,16 @@ php.buildComposerProject (finalAttrs: { pname = "castor"; - version = "0.14.0"; + version = "0.17.1"; src = fetchFromGitHub { owner = "jolicode"; repo = "castor"; rev = "v${finalAttrs.version}"; - hash = "sha256-sSIkXNW6RR1mx15dKouQLMaHBr5FEkTTc/0QIkWV8sg="; + hash = "sha256-ng32vuGlGffpkzf3hXu0sNbj0PCDu4DpZnMnbDV9pZk="; }; - patches = [ - # Upstream lock is invalid. https://github.com/jolicode/castor/issues/319 - (fetchpatch { - name = "fix-invalid-lock.patch"; - url = "https://github.com/jolicode/castor/commit/5ff0c3ecbdddad20146adbc2f055b83f5aadba0f.patch"; - hash = "sha256-1a3Dpk/UXp92Ugw9zSoLPsbWOJEuP2FBWc/pQ/EKwaM="; - }) - ]; - - vendorHash = "sha256-HfEjwlkozeuT4LDnYwiCu7T0spcf4GLhkd7Kc1VRnro="; + vendorHash = "sha256-E2NMWuUQXQ96NbKrcFnFGlxWR0tkd56MXk1bCL0N/sE="; nativeBuildInputs = [ installShellFiles ];