We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent afe71fe commit 3e10d88Copy full SHA for 3e10d88
1 file changed
flake.nix
@@ -9,9 +9,19 @@
9
outputs = { self, nixpkgs, flake-utils, ... }:
10
flake-utils.lib.eachDefaultSystem (system:
11
with import nixpkgs { inherit system; };
12
- with pkgs; {
+ with pkgs;
13
+ let
14
+ phpVersions = {
15
+ php81 = php81;
16
+ php82 = php82;
17
+ php83 = php83;
18
+ php84 = php84;
19
+ };
20
+ phpBins = lib.attrsets.mapAttrsToList (name: phpPkg:
21
+ pkgs.writeShellScriptBin name ''${phpPkg}/bin/php "$@"'') phpVersions;
22
+ in {
23
devShells.default = mkShell {
- buildInputs = [ php phpPackages.composer shellcheck zip ];
24
+ buildInputs = [ php phpPackages.composer shellcheck zip ] ++ phpBins;
25
};
26
});
27
}
0 commit comments