Commit graph

6 commits

Author SHA1 Message Date
Daniel Barlow
0312f7a999 fennelrepl look for .fnl before .lua
this means fennelrepl in nix-shell will prefer local
source files to generated lua files, making it easier
to change library code without restarting the shell
2023-09-09 00:11:35 +01:00
Daniel Barlow
eaa45906ff fennelrepl runs with --correlate
this is so that error message line numbers match up
2023-09-08 21:02:26 +01:00
Daniel Barlow
12e25722fa odhcp-script: delete stale dirs from previous runs
This requires adding LFS as a dependency because native Lua has
no way to iterate a directory, but it seems to be Not Huge and
hopefully we'll have other uses for it
2023-09-08 20:48:01 +01:00
Daniel Barlow
a19d12d6d7 fennelrepl add PREFIX/?/init.lua to lua load path 2023-07-08 23:08:25 +01:00
Daniel Barlow
708350711b allow running scripts using fennelrepl
e.g.

FENNEL_PATH=pkgs/?/init.fnl\;pkgs/?.fnl nix-shell --run "fennelrepl ./examples/acquire-delegated-prefix.fnl /tmp/boo eth1"
2023-07-08 23:08:24 +01:00
Daniel Barlow
c3bb33c9ce add fennelrepl package
Runs fennel using a Lua compiled with the same options as the
host system, and with packages set up so it can find all the local
Lua packages

To shorten the dev feedback loop further, allows FENNEL_PATH to be set
on the command line so you can point directly it at the Fennel sources
for some library you're working against instead of having to run
nix-build and compile them to Lua
2023-07-04 22:58:51 +01:00