Skip to content

Instantly share code, notes, and snippets.

@Jjunior130
Last active November 21, 2018 07:19
Show Gist options
  • Save Jjunior130/d26f5d877f14c73686176827da6e8c3d to your computer and use it in GitHub Desktop.
Save Jjunior130/d26f5d877f14c73686176827da6e8c3d to your computer and use it in GitHub Desktop.
(require '[me.raynes.fs :as fs])
(require '[me.raynes.fs.compression :refer [unzip]]
(defn download-datomic [version username password]
(let [credential (str username ":" password)]
(when-not (fs/file? "datomic.zip")
(fs/exec "cmd" "/C" (str "curl -L -u " credential " " download-url " > datomic.zip"))))
(unzip "datomic.zip" ".")
(fs/delete (fs/file "datomic.zip"))
(fs/exec "cmd" "/C" (str "move datomic-pro-* datomic")))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment