README
This commit is contained in:
parent
eb4f25f5c5
commit
efab1e28a4
4 changed files with 7 additions and 6 deletions
|
|
@ -9,7 +9,7 @@ $ cargo build --release
|
|||
## Run
|
||||
|
||||
```
|
||||
(babashka.pods/load-pod "examples/pods/pod-babashka-filewatcher/target/release/pod-babashka-filewatcher")
|
||||
(babashka.pods/load-pod "target/release/pod-babashka-filewatcher")
|
||||
(def chan (pod.babashka.filewatcher/watch "/tmp"))
|
||||
(require '[clojure.core.async :as async])
|
||||
(loop [] (prn (async/<!! chan)) (recur))
|
||||
|
|
|
|||
|
|
@ -7,6 +7,7 @@ Run `./compile`
|
|||
## Run
|
||||
|
||||
``` clojure
|
||||
(babashka.pods/load-pod "examples/pods/pod-babashka-hsqldb/pod-babashka-hsqldb")
|
||||
(pod.hsqldb/execute! "jdbc:hsqldb:mem:testdb;sql.syntax_mys=true" ["create table foo ( foo int );"])'
|
||||
(babashka.pods/load-pod "./pod-babashka-hsqldb")
|
||||
(pod.babashka.hsqldb/execute! "jdbc:hsqldb:mem:testdb;sql.syntax_mys=true" ["create table foo ( foo int );"])'
|
||||
;;=> [#:next.jdbc{:update-count 0}]
|
||||
```
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
(def stdin (PushbackInputStream. System/in))
|
||||
|
||||
(def lookup
|
||||
{'pod.hsqldb/execute! jdbc/execute!})
|
||||
{'pod.babashka.hsqldb/execute! jdbc/execute!})
|
||||
|
||||
(defn write [v]
|
||||
(bencode/write-bencode System/out v)
|
||||
|
|
@ -32,7 +32,7 @@
|
|||
op (keyword op)]
|
||||
(case op
|
||||
:describe (do (write {"format" "edn"
|
||||
"namespaces" [{"name" "pod.hsqldb"
|
||||
"namespaces" [{"name" "pod.babashka.hsqldb"
|
||||
"vars" [{"name" "execute!"}]}]})
|
||||
(recur))
|
||||
:invoke (let [var (-> (get message "var")
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ To run this:
|
|||
Then run as pod:
|
||||
|
||||
``` clojure
|
||||
(babashka.pods/load-pod ["examples/pods/pod-lispyclouds-sqlite/pod-lispyclouds-sqlite.py"])
|
||||
(babashka.pods/load-pod ["./pod-lispyclouds-sqlite.py"])
|
||||
(require '[pod.lispy-clouds.sqlite :as sqlite])
|
||||
(sqlite/execute! "create table if not exists foo ( int foo )")
|
||||
(sqlite/execute! "delete from foo")
|
||||
|
|
|
|||
Loading…
Reference in a new issue