View def-let-bindings.clj
This file contains 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
(->> (macroexpand '(let [~selection])) | |
second | |
(partition 2) | |
(map (fn [[sym val]] | |
(intern *ns* sym (eval val))))) |
View SketchSystems.spec
This file contains 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
SalesForce Requests | |
HTTP Call | |
success -> Success | |
400 response -> Exception | |
404 response -> Exception | |
401 response -> Refresh Token | |
other failure -> Wait | |
Refresh Token | |
token received -> HTTP Call | |
Wait |
View csv-to-kafka.clj
This file contains 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
#!/usr/bin/env bb | |
;; ^^ this tells our shell to use Babashka to run this script | |
;; read the file path of our CSV and the key field from the command line args | |
(def csv-file-path (first *command-line-args*)) | |
(def key-field (second *command-line-args*)) | |
;; read the CSV line-by-line into a data structure | |
(def csv-data | |
(with-open [reader (io/reader csv-file-path)] |
View datomic-update-cardinality-many-attr.clj
This file contains 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 datomic-update-cardinality-many | |
(:require [datomic.api :as d])) | |
(defn update-attr-txs [db entity-id attr values] | |
(let [current-vals (-> (d/q '[:find [?p ...] | |
:where [?id :intention/parents ?p] | |
:in $ ?id] | |
db | |
entity-id) | |
(set)) |
View SketchSystems.spec
This file contains 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
Loan | |
Non-existent | |
origination -> Payable | |
Payable | |
Current | |
payment time elapses -> Delinquent | |
full term reached -> End of Term | |
Delinquent | |
insufficient payment -> Delinquent | |
defaulted -> Default |
View rollup.config.js
This file contains 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
import commonjs from 'rollup-plugin-commonjs'; | |
export default { | |
entry: 'test.js', | |
format: 'iife', | |
moduleName: 'main', | |
plugins: [ | |
commonjs({ | |
include: 'x.js' | |
}) |