-
Notifications
You must be signed in to change notification settings - Fork 23
/
Copy pathproject.clj
202 lines (185 loc) · 10.9 KB
/
project.clj
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
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
(defproject rems "0.1.0-SNAPSHOT"
:description "Resource Entitlement Management System is a tool for managing access rights to resources, such as research datasets."
:url "https://github.com/CSCfi/rems"
:dependencies [[buddy/buddy-auth "2.1.0"]
[buddy/buddy-sign "3.2.0"]
[ch.qos.logback/logback-classic "1.2.3"]
[clj-commons/secretary "1.2.4"]
[clj-http "3.10.2"]
[cheshire "5.10.0"] ;; clj-http uses cheshire's json parsing
[clj-pdf "2.5.4"]
[clj-time "0.15.2"]
[cljs-ajax "0.8.0"]
[cljsjs/react "16.9.0-1"]
[cljsjs/react-dom "16.9.0-1"]
[cljsjs/react-dom-server "16.9.0-1"]
[cljsjs/react-select "2.4.4-0" :exclusions [cljsjs/react cljsjs/react-dom cljsjs/react-dom-server]]
[com.andrewmcveigh/cljs-time "0.5.2"]
[com.attendify/schema-refined "0.3.0-alpha5"]
[com.draines/postal "2.0.3"]
[com.fasterxml.jackson.datatype/jackson-datatype-joda "2.11.2"]
[com.rpl/specter "1.1.3"]
[com.taoensso/tempura "1.2.1"]
[compojure "1.6.2"]
[conman "0.8.4"] ;; 0.8.5 switches to next.jdbc, which breaks stuff and requires proper testing in production
[cprop "0.1.17"]
[funcool/promesa "5.1.0"]
[garden "1.3.10"]
[hiccup "1.0.5"]
[javax.xml.bind/jaxb-api "2.4.0-b180830.0359"]
[lambdaisland/deep-diff "0.0-47"]
[luminus-jetty "0.2.1"]
[luminus-migrations "0.6.7"]
[luminus-nrepl "0.1.6"]
[luminus/ring-ttl-session "0.3.3"]
[macroz/hiccup-find "0.6.1"]
[markdown-clj "1.10.5"]
[medley "1.3.0"]
[metosin/compojure-api "2.0.0-alpha30" :exclusions [cheshire com.fasterxml.jackson.core/jackson-core]]
[metosin/jsonista "0.2.7"]
[metosin/komponentit "0.3.10"]
[metosin/ring-swagger "0.26.2"]
[metosin/ring-swagger-ui "3.25.3"]
[mount "0.1.16"]
[ns-tracker "0.4.0"]
[org.apache.lucene/lucene-core "8.6.1"]
[org.apache.lucene/lucene-queryparser "8.6.1"]
[org.clojure/clojure "1.10.1"]
[org.clojure/clojurescript "1.10.520" :exclusions [com.fasterxml.jackson.core/jackson-core]]
[org.clojure/core.cache "1.0.207"]
[org.clojure/core.memoize "1.0.236"]
[org.clojure/tools.cli "1.0.194"]
[org.clojure/tools.logging "1.1.0"]
[org.postgresql/postgresql "42.2.16"]
[org.webjars.bower/tether "1.4.4"]
[org.webjars.npm/axe-core "4.0.2"]
[org.webjars.npm/better-dateinput-polyfill "3.0.0"]
[org.webjars.npm/better-dom "4.0.0"]
[org.webjars.npm/diff-match-patch "1.0.4"]
[org.webjars.npm/popper.js "1.16.1"]
[org.webjars/bootstrap "4.4.1-1"]
[org.webjars/font-awesome "5.12.0"]
[org.webjars/jquery "3.5.1"]
[prismatic/schema-generators "0.1.3"]
[px0/beautify-web "0.1.1"]
[re-frame "0.11.0"]
[reagent "0.9.1"]
[reagent-utils "0.3.3"]
[ring-cors "0.1.13"]
[ring-middleware-format "0.7.4"]
[ring-webjars "0.2.0"]
[ring/ring-core "1.8.1"]
[ring/ring-defaults "0.3.2"]
[ring/ring-devel "1.8.1"]
[ring/ring-servlet "1.8.1"]
[venantius/accountant "0.2.5"]]
:min-lein-version "2.0.0"
:source-paths ["src/clj" "src/cljc"]
:java-source-paths ["src/java"]
:javac-options ["-source" "8" "-target" "8"]
:test-paths ["src/clj" "src/cljc" "test/clj" "test/cljc"] ;; also run tests from src files
:resource-paths ["resources" "target/cljsbuild"]
:target-path "target/%s/"
:main rems.standalone
:migratus {:store :database :db ~(get (System/getenv) "DATABASE_URL" "postgresql://localhost/rems?user=rems")}
:plugins [[lein-cljfmt "0.6.7"]
[lein-cljsbuild "1.1.8"]
[lein-cprop "1.0.3"]
[lein-npm "0.6.2"]
[lein-shell "0.5.0"]
[migratus-lein "0.5.7"]]
:cljfmt {:paths ["src/clj" "src/cljc" "src/cljs" "test/clj" "test/cljc" "test/cljs"] ;; need explicit paths to include cljs
:remove-consecutive-blank-lines? false} ;; too many changes for now
:clean-targets ["target"]
:figwheel {:http-server-root "public"
:server-logfile "log/figwheel_server.log"
:nrepl-port 7002
:css-dirs ["target/resources/public/css"]
:nrepl-middleware [cider.piggieback/wrap-cljs-repl]}
:npm {:devDependencies [;; cljs testing
[karma "3.1.1"]
[karma-junit-reporter "2.0.1"]
[karma-cljs-test "0.1.0"]
[karma-chrome-launcher "2.2.0"]
;; printing to pdf
[puppeteer "2.0.0"]]}
:doo {:build "test"
:paths {:karma "node_modules/karma/bin/karma"}
:alias {:default [:chrome-headless]}
:karma {:config {"plugins" ["karma-junit-reporter"]
"reporters" ["progress" "junit"]
"junitReporter" {"outputDir" "target/test-results"}}}}
:aliases {"kaocha" ["with-profile" "test" "run" "-m" "kaocha.runner"]
"browsertests" ["do" ["cljsbuild" "once"] ["kaocha" "browser"]]
"cljtests" ["do" ["cljsbuild" "once"] ["kaocha"]]
"cljtests-ci" ["do" ["cljsbuild" "once"] ["kaocha" "--reporter" "kaocha.report/documentation"]]
"alltests" ["do" ["cljsbuild" "once"] ["kaocha"] ["doo" "once"]]
"test-ancient" ["do" ["cljsbuild" "once"] ["kaocha"] ["doo" "once"]]} ; for lein ancient to work and run all tests
:profiles
{:uberjar {:omit-source true
:prep-tasks [["shell" "sh" "-c" "mkdir -p target/uberjar/resources"]
["shell" "sh" "-c" "git describe --tags --long --always --dirty=-custom > target/uberjar/resources/git-describe.txt"]
["shell" "sh" "-c" "git rev-parse HEAD > target/uberjar/resources/git-revision.txt"]
"javac"
"compile"
["cljsbuild" "once" "min"]]
:cljsbuild {:builds {:min {:source-paths ["src/cljc" "src/cljs"]
:compiler {:output-dir "target/cljsbuild/public/js"
:output-to "target/cljsbuild/public/js/app.js"
:source-map "target/cljsbuild/public/js/app.js.map"
:optimizations :advanced
:pretty-print false
:closure-warnings {:externs-validation :off
:non-standard-jsdoc :off}
:warnings {:munged-namespace false} ;; for rems.actions.delete
:infer-externs :true ;; for window.rems.hooks to work
:externs ["react/externs/react.js"]}}}}
:aot :all
:uberjar-name "rems.jar"
:source-paths ["env/prod/clj"]
:resource-paths ["env/prod/resources" "target/uberjar/resources"]}
:dev [:project/dev :profiles/dev]
:test [:project/dev :project/test :profiles/test]
:project/dev {:dependencies [[binaryage/devtools "1.0.2"]
[cider/piggieback "0.5.1"]
[com.clojure-goes-fast/clj-memory-meter "0.1.3"]
[criterium "0.4.6"]
[doo "0.1.11"]
[lambdaisland/kaocha "1.0.669"]
[lambdaisland/kaocha-junit-xml "0.0.76"]
[etaoin "0.3.10"]
[figwheel-sidecar "0.5.20" :exclusions [org.clojure/tools.nrepl com.fasterxml.jackson.core/jackson-core]]
[re-frisk "1.0.0"] ;; coupled to the reagent version
[ring/ring-mock "0.4.0" :exclusions [cheshire]]
[se.haleby/stub-http "0.2.9"]
[com.icegreen/greenmail "1.6.0"]]
:plugins [[lein-ancient "0.6.15"]
[lein-doo "0.1.11"]
[lein-figwheel "0.5.20"]]
:jvm-opts ["-Drems.config=dev-config.edn"
"-Djdk.attach.allowAttachSelf" ; needed by clj-memory-meter on Java 9+
"-XX:-OmitStackTraceInFastThrow"]
:source-paths ["env/dev/clj"]
:resource-paths ["env/dev/resources"]
:repl-options {:init-ns rems
:welcome (rems/repl-help)}
:cljsbuild {:builds {:dev {:source-paths ["src/cljs" "src/cljc"]
:figwheel {:on-jsload "rems.spa/mount-components"}
:compiler {:main "rems.app"
:asset-path "/js/out"
:output-to "target/cljsbuild/public/js/app.js"
:output-dir "target/cljsbuild/public/js/out"
:source-map true
:optimizations :none
:pretty-print true
:warnings {:munged-namespace false} ;; for rems.actions.delete
:preloads [devtools.preload re-frisk.preload]}}
:test {:source-paths ["src/cljs" "src/cljc" "test/cljs"]
:compiler {:output-to "target/cljsbuild/test/test.js"
:output-dir "target/cljsbuild/test/out"
:main rems.cljs-tests
:optimizations :none}}}}}
:project/test {:jvm-opts ["-Drems.config=test-config.edn"]
:resource-paths ["env/test/resources"]}
:profiles/dev {}
:profiles/test {}})