diff --git a/src/main/lemondronor/advisorycircular.cljs b/src/main/lemondronor/advisorycircular.cljs index 0f0e38a..99d83e5 100644 --- a/src/main/lemondronor/advisorycircular.cljs +++ b/src/main/lemondronor/advisorycircular.cljs @@ -176,7 +176,8 @@ (defn screenshot [icao lat lon now] - (p/let [image-path (str icao "-" (util/format-utc-ts now) ".png") + (p/let [image-path (str (string/join "-" [@log-prefix icao (util/format-utc-ts now)]) + ".png") _ (adsbx/screenshot-aircraft icao lat lon {:timeout 30000 :output-path image-path @@ -300,7 +301,7 @@ "?:[(callsign {callsign}) ]" ;; Ideally neighbourhood as well as city or county, but ;; maybe just city. - "is circling over [{neighbourhood}, {locality}|{neighbourhood}, {county}|{locality}] " + "is circling over [{neighbourhood}, {locality}|{neighbourhood}, {county}|{locality}|{localadmin}] " ;; Altitude. "?:[at {alt} feet, ]" ;; Speed; @@ -515,7 +516,8 @@ lat lon) (log-warn "Skipping tweeting")) - (let [path (str icao "-" (util/format-utc-ts now) ".geojson")] + (let [path (str (string/join "-" [@log-prefix icao (util/format-utc-ts now)]) + ".geojson")] (util/write-file path (.stringify @@ -617,9 +619,7 @@ (.option "--log-prefix " "Log prefix to use") (.parse (.-argv js/process))) (logging/set-log-prefix! (or (.-logPrefix commander) "")) - (reset! log-prefix (if (.-logPrefix commander) - (str (.-logPrefix commander) "-") - "")) + (reset! log-prefix (or (.-logPrefix commander) "")) (let [start-time (current-time)] ;; If --config-path is specified, definitely try to read that ;; file. Otherwise, only read config.yaml if it exists.