Prepare scripts for deploy.

This commit is contained in:
Andrey Antukh 2016-02-21 16:42:35 +02:00
parent e2be16a421
commit 2aa95a3467
6 changed files with 219 additions and 17 deletions

2
scripts/dist Executable file
View file

@ -0,0 +1,2 @@
#!/bin/sh
lein trampoline run -m clojure.main scripts/dist.clj

21
scripts/dist.clj Normal file
View file

@ -0,0 +1,21 @@
(require '[cljs.build.api :as b]
'[cljs.tagged-literals])
(alter-var-root #'cljs.tagged-literals/*cljs-data-readers*
assoc 'ux/tr (fn [v] `(uxbox.locales/tr ~v)))
(println "Building ...")
(let [start (System/nanoTime)]
(b/build
(b/inputs "src")
{:main 'uxbox.core
:parallel-build false
:warnings {:ns-var-clash false}
:output-to "resources/public/js/main.js"
:output-dir "resources/public/js"
:optimizations :simple
:language-in :ecmascript5
:language-out :ecmascript5
:verbose true})
(println "... done. Elapsed" (/ (- (System/nanoTime) start) 1e9) "seconds"))