From 375df89de9b8a81727f12b2ff8994efe02e15b6d Mon Sep 17 00:00:00 2001 From: Oliver Davies Date: Mon, 18 Aug 2025 20:46:40 +0100 Subject: [PATCH] Automated commit Signed-off-by: Oliver Davies --- notes.adoc | 14 ++++++++++++++ shell.nix | 7 +++++++ 2 files changed, 21 insertions(+) create mode 100644 shell.nix diff --git a/notes.adoc b/notes.adoc index ec04b1f..80af76d 100644 --- a/notes.adoc +++ b/notes.adoc @@ -68,3 +68,17 @@ ec4c5890c8a75e93e1bb768f998e49ae7d2bf005e5e7c2a57dd2813b881e9758 podman run --rm ec4c5890c8a7 Hi, PHP Thames Valley! + +=== Using shell.nix + +nix-shell + +[nix-shell:~/php-thames-valley]$ php index.php + +Hi, PHP Thames Valley + +==== Running a command without entering a shell + +nix-shell --run "php index.php" + +Hi, PHP Thames Valley! diff --git a/shell.nix b/shell.nix new file mode 100644 index 0000000..d6d8241 --- /dev/null +++ b/shell.nix @@ -0,0 +1,7 @@ +{ + pkgs ? import { }, +}: + +pkgs.mkShell { + packages = [ pkgs.php ]; +}