mirror of
https://codeberg.org/icewind/flakelight-php.git
synced 2026-06-03 09:54:20 +02:00
add krb5 extension
This commit is contained in:
parent
4e1c0fc937
commit
052e3c8dc7
2 changed files with 31 additions and 4 deletions
|
|
@ -41,14 +41,19 @@
|
|||
composerJson;
|
||||
hasPsalm = pathExists config.psalmConfig;
|
||||
hasPhpCsFixer = pathExists config.phpCsFixerConfig;
|
||||
buildPhp = pkgs:
|
||||
(phpVersions.${head composerMeta.phpVersions} pkgs).buildEnv {
|
||||
buildPhpVersion = pkgs: version:
|
||||
(phpVersions.${version} pkgs).buildEnv {
|
||||
extensions = {
|
||||
enabled,
|
||||
all,
|
||||
}:
|
||||
enabled ++ (config.phpExtensions all);
|
||||
}: let
|
||||
extra = {
|
||||
krb5 = pkgs.callPackage ./pkgs/php-krb5.nix {php = phpVersions.${version} pkgs;};
|
||||
};
|
||||
in
|
||||
enabled ++ (config.phpExtensions (all // extra));
|
||||
};
|
||||
buildPhp = pkgs: buildPhpVersion pkgs (head composerMeta.phpVersions);
|
||||
in
|
||||
warnIf (! builtins ? readFileType) "Unsupported Nix version in use."
|
||||
{
|
||||
|
|
@ -79,6 +84,7 @@ in
|
|||
fileFilter
|
||||
(file:
|
||||
file.hasExt "php"
|
||||
|| file.hasExt "stub"
|
||||
|| file.hasExt "phpstub"
|
||||
|| match "snapshot__.*\.snap" file.name != null
|
||||
|| elem file.name [".php-cs-fixer.dist.php" "psalm.xml" "package.json" "package.lock"])
|
||||
|
|
@ -150,6 +156,7 @@ in
|
|||
}
|
||||
// optionalAttrs hasPhpCsFixer {
|
||||
"*.php" = "${getExe php-cs-fixer} fix";
|
||||
"*.stub" = "${getExe php-cs-fixer} fix";
|
||||
"*.phpstub" = "${getExe php-cs-fixer} fix";
|
||||
});
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue