summaryrefslogtreecommitdiff
path: root/shell.nix
diff options
context:
space:
mode:
Diffstat (limited to 'shell.nix')
-rw-r--r--shell.nix16
1 files changed, 16 insertions, 0 deletions
diff --git a/shell.nix b/shell.nix
new file mode 100644
index 0000000..295bacb
--- /dev/null
+++ b/shell.nix
@@ -0,0 +1,16 @@
+with import <nixpkgs> {};
+with lua53Packages;
+
+let
+ libs = [lua5_3 lua53Packages.lpeg];
+in
+stdenv.mkDerivation rec {
+ name = "lua-env";
+ buildInputs = libs;
+
+ shellHook = ''
+ export LUA_CPATH="${lib.concatStringsSep ";" (map getLuaCPath libs)};./?.so"
+ export LUA_PATH="${lib.concatStringsSep ";" (map getLuaPath libs)};./?.lua"
+ '';
+}
+