From 362b19ae2505fc08054efedc27c547d5e94c8f02 Mon Sep 17 00:00:00 2001 From: Simon Brooke Date: Mon, 10 Apr 2023 14:41:50 +0100 Subject: [PATCH] Last minute but: was failing to read the SYSOUT file from the jar. --- src/beowulf/io.clj | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/beowulf/io.clj b/src/beowulf/io.clj index 3ad7b57..62ead4c 100644 --- a/src/beowulf/io.clj +++ b/src/beowulf/io.clj @@ -46,7 +46,7 @@ ;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; -(def ^:constant default-sysout "resources/lisp1.5.lsp") +(def ^:constant default-sysout "lisp1.5.lsp") (defn- full-path [fp] @@ -154,18 +154,18 @@ **NOTE THAT** this is an extension function, not available in strct mode." ([] - (SYSIN (or (:read *options*) default-sysout))) + (SYSIN (or (:read *options*) (str "resources/" default-sysout)))) ([filename] (let [fp (file (full-path (str filename))) file (when (and (.exists fp) (.canRead fp)) fp) res (try (resource filename) (catch Throwable _ nil)) content (try (READ (slurp (or file res))) - (catch Throwable any + (catch Throwable _ (throw (ex-info "Ne can ārǣde" {:context "SYSIN" - :filepath fp} - any))))] + :filename filename + :filepath fp}))))] (swap! oblist #(when (or % (seq content)) (resolve-subroutines content))))))