-
Notifications
You must be signed in to change notification settings - Fork 0
/
doc.clj
26 lines (23 loc) · 785 Bytes
/
doc.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
(ns doc
(:require
[babashka.fs :as fs]
[clojure.java.io :as io]
[dinodoc.statecharts :as statecharts]))
(fs/delete-tree "docs")
(fs/create-dirs "docs")
(with-open [writer (io/writer "docs/index.md")]
(binding [*out* writer]
(let [prefix "examples/statecharts/src/"]
(println "---")
(println "title: Statecharts")
(println "---")
(statecharts/render-machine-var
(requiring-resolve 'example.statecharts/machine)
{:filename-add-prefix prefix})
(statecharts/render-machine-var
(requiring-resolve 'example.statecharts/dog-walk)
{:filename-add-prefix prefix})
(statecharts/render-machine-var
(requiring-resolve 'example.statecharts/regions)
{:filename-add-prefix prefix}))))
(shutdown-agents)