This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ clojure -Sdescribe | |
{:version "1.11.1.1149" | |
:config-files ["/nix/store/w0fqc8djks9is9ar13r23g2frdld70c6-clojure-1.11.1.1149/deps.edn" "/var/lib/gitlab-runner/.clojure/deps.edn" "deps.edn" ] | |
:config-user "/var/lib/gitlab-runner/.clojure/deps.edn" | |
:config-project "deps.edn" | |
:install-dir "/nix/store/w0fqc8djks9is9ar13r23g2frdld70c6-clojure-1.11.1.1149" | |
:config-dir "/var/lib/gitlab-runner/.clojure" | |
:cache-dir ".cpcache" | |
:force false | |
:repro false |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
commands: | |
install_bb: | |
description: "Install Babashka" | |
parameters: | |
version: | |
default: "0.4.4" | |
type: string | |
steps: | |
- restore_cache: | |
keys: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ava.lang.Error: IO exception from Etch | |
at etch.EtchStore.refForHash(EtchStore.java:88) | |
at etch.EtchStore.storeRef(EtchStore.java:118) | |
at etch.EtchStore.lambda$storeRef$0(EtchStore.java:128) | |
at convex.core.data.SignedData.updateRefs(SignedData.java:224) | |
at convex.core.data.SignedData.updateRefs(SignedData.java:45) | |
at etch.EtchStore.storeRef(EtchStore.java:133) | |
at etch.EtchStore.storeTopRef(EtchStore.java:99) | |
at convex.core.data.ACell.createPersisted(ACell.java:431) | |
at convex.core.data.ACell.createPersisted(ACell.java:444) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; Decompiling and pretty printing a WASM program such as "my_program.wasm": | |
;; | |
;; $ bb babashka_wasm.clj my_program.wasm | |
;; | |
;; Following WASM specs 1.1 | |
(require '[babashka.deps :as deps]) | |
(deps/add-deps '{:deps {io.helins/wasm {:mvn/version "0.0.0-alpha2"}}}) | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; Test should fail because it requires `java.nio.DirectByteBufferR` | |
(require '[babashka.deps :as deps]) | |
(deps/add-deps '{:deps {io.helins/binf {:mvn/version "1.0.0-beta1"}}}) | |
(ns helins.binf.example.mmap-file | |
"Using BinF for writing and reading to a memory-mapped file on the JVM. | |
BinF protocols are implemented for ByteBuffer, parent of MappedByteBuffer." |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; For instance, build tasks produce garbage and an interceptor-like interface is a great match | |
;; | |
{:tasks {:build-something {:enter {:babashka/process ["bash" "-c" "touch file.txt"]} | |
:leave {:babashka/process ["bash" "-c" "rm file.txt"]}}}} | |
;; Clearer than splitting the task in two | |
;; | |
{:tasks {:create-file {:babashka/process ["bash" "-c" "touch file.txt"]} | |
:delete-file {:babashka/process ["bash" "-c" "rm file.txt"]} | |
:build-something {:babashka/args [:do :create-file |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# A fatal error has been detected by the Java Runtime Environment: | |
# | |
# SIGSEGV (0xb) at pc=0x00007fe1df8c4f91, pid=27960, tid=27980 | |
# | |
# JRE version: OpenJDK Runtime Environment (Zulu11.39+15-CA) (11.0.7+10) (build 11.0.7+10-LTS) | |
# Java VM: OpenJDK 64-Bit Server VM (11.0.7+10-LTS, mixed mode, tiered, compressed oops, g1 gc, linux-amd64) | |
# Problematic frame: | |
# C [wasmer_jni2309101336629026624.lib+0x5ef91] _$LT$hashbrown..raw..RawTable$LT$T$GT$$u20$as$u20$core..ops..drop..Drop$GT$::drop::hfb03333fcdd0f7eb+0x31 | |
# |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns hooks.fulcro | |
"" | |
{:author "Adam Helins"} | |
(:require [clj-kondo.hooks-api :as hook])) | |
(defn defmutation | |
[{:keys [node]}] | |
(let [[_call | |
sym | |
& arg+] (:children node) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defn split-with | |
"Semi lazy alternative to `split-with`" | |
[pred coll] | |
(let [acc (transient [])] | |
(loop [[v | |
:as vs] coll] | |
(if (seq vs) |