This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2022-03-13
Channels
- # announcements (1)
- # asami (6)
- # babashka (7)
- # beginners (94)
- # biff (1)
- # calva (18)
- # clj-kondo (35)
- # cljsrn (1)
- # clojure (7)
- # clojure-europe (1)
- # clojure-nl (1)
- # clojure-uk (1)
- # clojurescript (18)
- # core-logic (1)
- # datalog (2)
- # editors (10)
- # exercism (2)
- # figwheel-main (1)
- # fulcro (2)
- # introduce-yourself (1)
- # lsp (33)
- # malli (7)
- # off-topic (3)
- # pedestal (1)
- # portal (2)
- # re-frame (16)
- # releases (1)
- # shadow-cljs (10)
- # specter (3)
- # tools-deps (8)
What would be a recommended way to read from stdin
using nbb? fs? process?
Ah cool, sure
Is there something simpler maybe?
OK, here we go! #specter in #babashka, all specter's tests are passing! Install the latest dev preview:
bash <(curl ) --version 0.7.8-SNAPSHOT --dir .
Then try this script:
(require '[babashka.deps :as deps])
(deps/add-deps '{:deps {com.rpl/specter {:git/url ""
:git/sha "8ba809a2cd35d3b6f8c5287e6bd3b4e06e42f6dc"}}})
(require '[com.rpl.specter :as s])
(s/transform [(s/walker number?) odd?] inc {:a 1 :b [1 2 3]})
with:
./bb specter.clj
and it should print:
{:a 2, :b [2 2 4]}
🤯 3
🚀 5
One more reason to finally learn how to use Specter!
Babashka 0.7.8! This release improves compatibility with several libraries: https://github.com/aysylu/loom, https://www.hugsql.org/ and https://github.com/redplanetlabs/specter! To use specter in babashka, use the following coordinates:
{:deps {com.rpl/specter {:git/url ""
:git/sha "8ba809a2cd35d3b6f8c5287e6bd3b4e06e42f6dc"}}}
Hopefully the compatibility commit can be upstreamed back into specter at some point.
• Add clojure.data.priority-map
as built-in library - this makes babashka compatible with https://github.com/aysylu/loom
• Add part of clojure.tools.reader.reader-types
to support https://www.hugsql.org/
• https://github.com/babashka/babashka/issues/1204 add property babashka.config
to reflect bb.edn
location (https://github.com/mknoszlig)
• Several fixes and enhancements to run Red Planet Lab's https://github.com/borkdude/specter/commit/8ba809a2cd35d3b6f8c5287e6bd3b4e06e42f6dc library in babashka
• https://github.com/babashka/babashka/issues/1199: support print-method
impls on records
• babashka.fs
: add windows?
predicate
• SCI: add *clojure-version*
and (clojure-version)
• Add java.util.zip.Deflater
and java.util.zip.DeflaterOutputStream
• SCI: implement declare
as macro
• https://github.com/babashka/babashka/issues/938: drop location metadata from symbols, except top level
Full changelogs: https://github.com/babashka/babashka/blob/master/CHANGELOG.md🎉 6