From 3f6e42b10b86a6bb753c73a37119aa08a584b107 Mon Sep 17 00:00:00 2001 From: bugdone Date: Sat, 10 Feb 2024 18:22:40 +0200 Subject: [PATCH] Fix windows parsing --- src/hsbox/demo.clj | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/hsbox/demo.clj b/src/hsbox/demo.clj index ce3fb7b..d388dc7 100644 --- a/src/hsbox/demo.clj +++ b/src/hsbox/demo.clj @@ -50,12 +50,18 @@ (def demoinfo-dir-path dir)) (defn find-demoparser [] - (let [csdemoparser (str demoinfo-dir-path "/csdemoparser") + (let [csdemoparser-exe (str demoinfo-dir-path "/csdemoparser.exe") + csdemoparser (str demoinfo-dir-path "/csdemoparser") + csdemoparser-dev-exe (str demoinfo-dir-path "/target/release/csdemoparser.exe") csdemoparser-dev (str demoinfo-dir-path "/target/release/csdemoparser") + demoinfogo-exe (str demoinfo-dir-path "/demoinfogo.exe") demoinfogo (str demoinfo-dir-path "/demoinfogo")] (cond + (file-exists? csdemoparser-exe) [csdemoparser-exe] (file-exists? csdemoparser) [csdemoparser] + (file-exists? csdemoparser-dev-exe) [csdemoparser-dev-exe] (file-exists? csdemoparser-dev) [csdemoparser-dev] + (file-exists? demoinfogo-exe) [demoinfogo-exe "-hsbox"] (file-exists? demoinfogo) [demoinfogo "-hsbox"] :else (throw (Exception. (str "No demo parser found in '" demoinfo-dir-path "'"))))))