Skip to content

Instantly share code, notes, and snippets.

View coltnz's full-sized avatar

Colin Taylor coltnz

View GitHub Profile
@coltnz
coltnz / cursive-boot-deps.clj
Last active May 9, 2018 06:32
Cursive, Boot and deps
(task-options!
pom {:project project
:version version}
jar {:main ...
:file ...)})
(require '[boot-tools-deps.core :refer [deps load-deps]])
(deftask build
"Build the project locally as a JAR."

Keybase proof

I hereby claim:

  • I am coltnz on github.
  • I am colint (https://keybase.io/colint) on keybase.
  • I have a public key ASDX1cMiJ3KBwd2QP1akc82AiU9K_45imZpek0TnLRldPwo

To claim this, I am signing this object:

@coltnz
coltnz / onename
Created October 24, 2015 08:22
onename
Verifying that +colin is my blockchain ID. https://onename.com/colin
@coltnz
coltnz / clojure-repl-log-level-logback
Created February 12, 2015 00:28
set clojure tools logging level in repl (logback version)
; in user.clj
(:import [org.slf4j LoggerFactory]
[ch.qos.logback.classic Logger Level]
(defn set-log-level! [level]
(.. (LoggerFactory/getLogger org.slf4j.Logger/ROOT_LOGGER_NAME)
(setLevel (Level/valueOf (.toUpperCase (name level))))))
;; FLATLAND/USEFUL bug ?
;; when hayt gets required it requires flatland.useful.map where the update fn has disappeared
;; so it fails to load
;; we patch a no-op since we don't use update
;; prob something to do with intro of clojure.core/update but god knows how
(require '[flatland.useful.map])
(in-ns 'flatland.useful.map)
(defn flatland.useful.map/update
[m key f & args]