From 1f44c99ef120414246a1bea413a953bc779b8aad Mon Sep 17 00:00:00 2001 From: XeroOl Date: Sat, 8 Jun 2024 12:18:52 -0500 Subject: [PATCH] fix sh function I think it would probably be better to just make a shell script instead of this whole lua stuff, but I'll leave it for now. --- Makefile | 6 ++++-- tools/util/sh.fnl | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 36cf08d..b283c2b 100644 --- a/Makefile +++ b/Makefile @@ -28,7 +28,6 @@ $(EXE): $(SRC) clean: rm -f $(EXE) - rm -rf $(BUILD_DIR) test: TESTING=1 $(FENNEL) $(FENNELFLAGS) --add-fennel-path "test/faith/?.fnl" test/init.fnl @@ -44,7 +43,10 @@ testall: $(MAKE) test LUA=luajit docs: - $(FENNEL) $(FENNELFLAGS) --add-fennel-path "tools/?.fnl" tools/gen-docs.fnl + $(FENNEL) $(FENNELFLAGS) tools/gen-docs.fnl + +install-deps: + $(FENNEL) $(FENNELFLAGS) tools/vendor.fnl install: $(EXE) mkdir -p $(DESTDIR)$(BINDIR) && cp $< $(DESTDIR)$(BINDIR)/ diff --git a/tools/util/sh.fnl b/tools/util/sh.fnl index 7236363..ebc89b7 100644 --- a/tools/util/sh.fnl +++ b/tools/util/sh.fnl @@ -7,7 +7,7 @@ (= (type arg) :table) (. arg 1) ;; simple string skips escaping - (arg:find "^[a-zA-Z0-9/_-%.]+$") + (arg:find "^[a-zA-Z0-9/_%.-]+$") arg ;; full escaping (.. "'"