Created
July 26, 2014 08:57
-
-
Save thheller/6c3ad4c880b035921ce6 to your computer and use it in GitHub Desktop.
timestamping the output files
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defn add-module-build-times [state] | |
(let [now (System/currentTimeMillis)] | |
(reduce (fn [state name] | |
(assoc-in state [:modules name :js-name] (str now "-" (clojure.core/name name) ".js"))) | |
state | |
(keys (:modules state))))) | |
;; then in the build step | |
(-> state | |
(define-modules) | |
(add-module-build-times) | |
(cljs/step-compile-modules) | |
(cljs/closure-optimize) | |
(cljs/flush-modules-to-disk)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment