-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathbuild.boot
104 lines (91 loc) · 3.57 KB
/
build.boot
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
(def +version+ "0.1.1")
(set-env!
:source-paths #{"src/main"}
:resource-paths #{"resources"}
:dependencies '[[org.clojure/clojurescript "1.9.229" :scope "provided"]
[org.omcljs/om "1.0.0-alpha44" :scope "provided"
:exclusions [cljsjs/react]]
[cljsjs/react-with-addons "15.3.1-0" :scope "test"]
[cljsjs/react-dom "15.3.1-0" :scope "test"
:exclusions [cljsjs/react]]
[com.cognitect/transit-clj "0.8.288" :scope "test"]
[devcards "0.2.1-7" :scope "test"
:exclusions [cljsjs/react cljsjs/react-dom]]
[cljsjs/recharts "0.13.3-0" :scope "test"
:exclusions [cljsjs/react]]
[com.cemerick/piggieback "0.2.1" :scope "test"]
[pandeiro/boot-http "0.7.3" :scope "test"]
[adzerk/boot-cljs "1.7.228-1" :scope "test"]
[adzerk/boot-cljs-repl "0.3.3" :scope "test"]
[crisptrutski/boot-cljs-test "0.2.2-SNAPSHOT" :scope "test"]
[adzerk/boot-reload "0.4.12" :scope "test"]
[adzerk/bootlaces "0.1.13" :scope "test"]
[org.clojure/tools.nrepl "0.2.12" :scope "test"]
[weasel "0.7.0" :scope "test"]
[boot-codox "0.9.6" :scope "test"]])
(require
'[adzerk.boot-cljs :refer [cljs]]
'[adzerk.boot-cljs-repl :refer [cljs-repl start-repl]]
'[adzerk.boot-reload :refer [reload]]
'[adzerk.bootlaces :refer [bootlaces! push-release]]
'[crisptrutski.boot-cljs-test :refer [test-cljs]]
'[pandeiro.boot-http :refer [serve]]
'[codox.boot :refer [codox]])
(bootlaces! +version+ :dont-modify-paths? true)
(task-options!
pom {:project 'omify
:version +version+
:description "om.next-ify plain React components."
:url "https://github.com/compassus/omify"
:scm {:url "https://github.com/compassus/omify"}
:license {"name" "Eclipse Public License"
"url" "http://www.eclipse.org/legal/epl-v10.html"}})
(deftask build-jar []
(set-env! :resource-paths #{"src/main"})
(adzerk.bootlaces/build-jar))
(deftask release-clojars! []
(comp
(build-jar)
(push-release)))
(deftask deps [])
(deftask devcards []
(set-env! :source-paths #(conj % "src/devcards"))
(comp
(serve)
(watch)
(cljs-repl)
(reload :on-jsload 'omify.devcards.core/init!)
(speak)
(cljs :source-map true
;:optimizations :advanced
:compiler-options {:devcards true
:parallel-build true}
:ids #{"js/devcards"})))
(deftask testing []
(set-env! :source-paths #(conj % "src/test"))
identity)
(ns-unmap 'boot.user 'test)
(deftask test
[e exit? bool "Enable flag."]
(let [exit? (cond-> exit?
(nil? exit?) not)]
(comp
(testing)
(test-cljs
:js-env :node
:namespaces #{'omify.tests}
:cljs-opts {:parallel-build true}
:exit? exit?))))
(deftask auto-test []
(comp
(watch)
(speak)
(test :exit? false)))
(deftask release-devcards []
(set-env! :source-paths #(conj % "src/devcards"))
(comp
(cljs :optimizations :advanced
:ids #{"js/devcards"}
:compiler-options {:devcards true
:elide-asserts true})
(target)))