dev / templates / bot / shadow-cljs.edn
 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
;; Four SEPARATE builds — one per process entry — so the two native WebRTC
;; stacks can never meet in one module graph (the two-stack law, house rule 11):
;;   :main   → dist/main.js       value-imports ardegazu-peer-kit ONLY
;;   :worker → dist/worker.js     value-imports ardegazu-rooms-kit ONLY
;;   :train  → dist/rl/train.js   peer-kit gyms + train-kit (no rooms-kit)
;;   :link   → dist/fleet/link.js peer-kit identity only
;; npm deps stay external ESM imports (:js-provider :import) — the kits'
;; libdatachannel natives and tfjs-node must never be bundled. scripts/build.mjs
;; assembles the four outputs into dist/ and normalizes gensyms for the
;; deterministic committed dist (deploy/check-dist.sh).
;;
;; :exports on :main are the pure-function surface the black-box test suite
;; exercises against the committed dist (test/*.test.mjs).
{:deps {:aliases [:dev]}
 :builds
 {:main
  {:target :esm
   :output-dir "target/esm-main"
   :compiler-options {:optimizations :simple
                      :source-map false
                      ;; serial compile: the JVM-global gensym counter numbers
                      ;; every reify/deftype hoisted var — under parallel
                      ;; compilation the counter interleaves
                      ;; nondeterministically, and THAT class of delta cannot
                      ;; be text-normalized after the fact the way
                      ;; scripts/normalize-gensyms.mjs renumbers dyn vars
                      :parallel-build false}
   :js-options {:js-provider :import}
   :modules
   {:main {:entries [__NAME__.main]
           :init-fn __NAME__.main/init
           :exports {loadConfig __NAME__.config/load-config
                     shouldReap __NAME__.main/should-reap
                     roomKey __NAME__.rooms/room-key
                     appOfHost __NAME__.rooms/app-of-host
                     backoffDelay __NAME__.rooms/backoff-delay
                     joinWorkerRoom __NAME__.rooms/join-worker-room
                     attachBehavior __NAME__.behaviors/attach-behavior}}}}

  :worker
  {:target :esm
   :output-dir "target/esm-worker"
   :compiler-options {:optimizations :simple
                      :source-map false
                      ;; serial compile: the JVM-global gensym counter numbers
                      ;; every reify/deftype hoisted var — under parallel
                      ;; compilation the counter interleaves
                      ;; nondeterministically, and THAT class of delta cannot
                      ;; be text-normalized after the fact the way
                      ;; scripts/normalize-gensyms.mjs renumbers dyn vars
                      :parallel-build false}
   :js-options {:js-provider :import}
   :modules
   {:worker {:entries [__NAME__.worker]
             :init-fn __NAME__.worker/init}}}

  :train
  {:target :esm
   :output-dir "target/esm-train"
   :compiler-options {:optimizations :simple
                      :source-map false
                      ;; serial compile: the JVM-global gensym counter numbers
                      ;; every reify/deftype hoisted var — under parallel
                      ;; compilation the counter interleaves
                      ;; nondeterministically, and THAT class of delta cannot
                      ;; be text-normalized after the fact the way
                      ;; scripts/normalize-gensyms.mjs renumbers dyn vars
                      :parallel-build false}
   :js-options {:js-provider :import}
   :modules
   {:train {:entries [__NAME__.rl.train]
            :init-fn __NAME__.rl.train/init}}}

  :link
  {:target :esm
   :output-dir "target/esm-link"
   :compiler-options {:optimizations :simple
                      :source-map false
                      ;; serial compile: the JVM-global gensym counter numbers
                      ;; every reify/deftype hoisted var — under parallel
                      ;; compilation the counter interleaves
                      ;; nondeterministically, and THAT class of delta cannot
                      ;; be text-normalized after the fact the way
                      ;; scripts/normalize-gensyms.mjs renumbers dyn vars
                      :parallel-build false}
   :js-options {:js-provider :import}
   :modules
   {:link {:entries [__NAME__.fleet.link]
           :init-fn __NAME__.fleet.link/init}}}}}

static mirror of HEAD · about · clone: git clone https://git.ardegazu.ro/dev.git