~subsetpark/ec

ba838228d359a4959dd57ff46d4564d3955c17d8 — Zach Smith 27 days ago 2f3cbf5 v0.5.1
when-let
1 files changed, 13 insertions(+), 14 deletions(-)

M main.janet
M main.janet => main.janet +13 -14
@@ 83,17 83,16 @@

(defn main
  [& _args]
  (let [res (argparse ;params)]
    (when res
      (match res
        {"file" filename} (->>
                           filename
                           (slurp)
                           (string/split "\n")
                           (repl/handle-lines))
        {:default inputs} (->
                           inputs
                           (string/join " ")
                           (tuple)
                           (repl/handle-lines))
        _ (repl/repl)))))
  (when-let [res (argparse ;params)]
    (match res
      {"file" filename} (->>
                         filename
                         (slurp)
                         (string/split "\n")
                         (repl/handle-lines))
      {:default inputs} (->
                         inputs
                         (string/join " ")
                         (tuple)
                         (repl/handle-lines))
      _ (repl/repl))))