Merge pull request #259426 from etu/composer-keep-versions-in-sync
php.packages.composer: Make sure that both composers use the same version
This commit is contained in:
commit
05c36949c0
@ -1,7 +1,9 @@
|
||||
{ callPackage, stdenvNoCC, lib, fetchFromGitHub, makeBinaryWrapper }:
|
||||
{ php, callPackage, stdenvNoCC, lib, fetchFromGitHub, makeBinaryWrapper }:
|
||||
|
||||
let
|
||||
composer = callPackage ./composer-phar.nix { };
|
||||
composer = callPackage ./composer-phar.nix {
|
||||
inherit (php.packages.composer) version pharHash;
|
||||
};
|
||||
|
||||
composerKeys = stdenvNoCC.mkDerivation (finalComposerKeysAttrs: {
|
||||
pname = "composer-keys";
|
||||
|
@ -10,15 +10,17 @@
|
||||
, stdenvNoCC
|
||||
, unzip
|
||||
, xz
|
||||
, version
|
||||
, pharHash
|
||||
}:
|
||||
|
||||
stdenvNoCC.mkDerivation (finalAttrs: {
|
||||
pname = "composer-phar";
|
||||
version = "2.6.5";
|
||||
inherit version;
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://github.com/composer/composer/releases/download/${finalAttrs.version}/composer.phar";
|
||||
hash = "sha256-mhjho6rby5TBuv1sSpj/kx9LQ6RW70hXUTBGbhnwXdY=";
|
||||
hash = pharHash;
|
||||
};
|
||||
|
||||
dontUnpack = true;
|
||||
|
@ -1,7 +1,16 @@
|
||||
{ lib, callPackage, fetchFromGitHub, php, unzip, _7zz, xz, git, curl, cacert, makeBinaryWrapper }:
|
||||
|
||||
php.buildComposerProject (finalAttrs: {
|
||||
composer = callPackage ../../../build-support/php/pkgs/composer-phar.nix { };
|
||||
# Hash used by ../../../build-support/php/pkgs/composer-phar.nix to
|
||||
# use together with the version from this package to keep the
|
||||
# bootstrap phar file up-to-date together with the end user composer
|
||||
# package.
|
||||
passthru.pharHash = "sha256-mhjho6rby5TBuv1sSpj/kx9LQ6RW70hXUTBGbhnwXdY=";
|
||||
|
||||
composer = callPackage ../../../build-support/php/pkgs/composer-phar.nix {
|
||||
inherit (finalAttrs) version;
|
||||
inherit (finalAttrs.passthru) pharHash;
|
||||
};
|
||||
|
||||
pname = "composer";
|
||||
version = "2.6.5";
|
||||
|
Loading…
Reference in New Issue
Block a user