nix support

This commit is contained in:
hakutaku
2025-08-17 12:24:35 +03:00
parent 7666db5667
commit d7f8037a18
2 changed files with 40 additions and 0 deletions

5
.envrc Normal file
View File

@@ -0,0 +1,5 @@
use nix
# hack
# https://github.com/direnv/direnv/issues/1345
mkdir -p $TMPDIR

35
shell.nix Normal file
View File

@@ -0,0 +1,35 @@
let
nixpkgs = fetchTarball "https://github.com/NixOS/nixpkgs/tarball/nixos-25.05";
pkgs = import nixpkgs {
config = { };
overlays = [ ];
};
packages =
let
phpForRuntimeWithXDebug = (
pkgs.php82.buildEnv {
extensions = (
{ enabled, all }:
enabled
++ (with all; [
xdebug
])
);
}
);
in
[
phpForRuntimeWithXDebug
pkgs.treefmt
pkgs.nixfmt-rfc-style
pkgs.gnumake
pkgs.php82Extensions.curl
pkgs.php82Packages.composer
];
in
pkgs.mkShell {
inherit packages;
}