Fixed incorrectly parenthesized tests.

Fixed incorrectly parenthesized tests.

--- test/sablono/core_test.cljs
+++ test/sablono/core_test.cljs
@@ -12,83 +12,83 @@

 (deftest tag-names
   (testing "basic tags"
-    (is (= (html-str [:div])) "

")
-    (is (= (html-str ["div"])) "

")
-    (is (= (html-str ['div])) "

"))
+    (is (= (html-str [:div]) "

"))
+    (is (= (html-str ["div"]) "

"))
+    (is (= (html-str ['div]) "

")))
   (testing "tag syntax sugar"
-    (is (= (html-str [:div#foo])) "

")
-    (is (= (html-str [:div.foo])) "

")
-    (is (= (html-str [:div.foo (str "bar" "baz")])) "
barbaz
")
-    (is (= (html-str [:div.a.b])) "

")
-    (is (= (html-str [:div.a.b.c])) "

")
-    (is (= (html-str [:div#foo.bar.baz])) "

")))
+    (is (= (html-str [:div#foo]) "

"))
+    (is (= (html-str [:div.foo]) "

"))
+    (is (= (html-str [:div.foo (str "bar" "baz")]) "
barbaz
"))
+    (is (= (html-str [:div.a.b]) "

"))
+    (is (= (html-str [:div.a.b.c]) "

"))
+    (is (= (html-str [:div#foo.bar.baz]) "

"))))

 (deftest tag-contents
   (testing "empty tags"
-    (is (= (html-str [:div])) "

")
-    (is (= (html-str [:h1])) "

")
+    (is (= (html-str [:div]) "

"))
+    (is (= (html-str [:h1]) "

"))
     ;; [:script] ""
-    (is (= (html-str [:text])) "<text></text>")
-    (is (= (html-str [:a])) "")
-    (is (= (html-str [:iframe])) "")
-    (is (= (html-str [:title])) "<title></title>")
-    (is (= (html-str [:section])) "

"))
+    (is (= (html-str [:text]) "<text></text>"))
+    (is (= (html-str [:a]) ""))
+    (is (= (html-str [:iframe]) ""))
+    (is (= (html-str [:title]) "<title></title>"))
+    (is (= (html-str [:section]) "

")))
   (testing "tags containing text"
-    (is (= (html-str [:text "Lorem Ipsum"])) "<text>Lorem Ipsum</text>"))
+    (is (= (html-str [:text "Lorem Ipsum"]) "<text>Lorem Ipsum</text>")))
   (testing "contents are concatenated"
-    (is (= (html-str [:div "foo" "bar"])) "
foobar
")
-    (is (= (html-str [:div [:p] [:br]])) "

"))
+    (is (= (html-str [:div "foo" "bar"]) "
foobar
"))
+    (is (= (html-str [:div [:p] [:br]]) "

")))
   (testing "seqs are expanded"
-    (is (= (html-str [:div (list "foo" "bar")])) "
foobar
")
+    (is (= (html-str [:div (list "foo" "bar")]) "
foobar
"))
     ;; (is (= (html (list [:p "a"] [:p "b"])) "
a

b
"))
     )
   (testing "vecs don't expand - error if vec doesn't have tag name"
     (is (thrown? js/Error (html (vector [:p "a"] [:p "b"])))))
   (testing "tags can contain tags"
-    (is (= (html-str [:div [:p]])) "

")
-    (is (= (html-str [:div [:b]])) "

")
-    (is (= (html-str [:p [:span [:a "foo"]]])) "
foo
")))
+    (is (= (html-str [:div [:p]]) "

"))
+    (is (= (html-str [:div [:b]]) "

"))
+    (is (= (html-str [:p [:span [:a "foo"]]]) "
foo
"))))

 (deftest tag-attributes
   (testing "tag with blank attribute map"
-    (is (= (html-str [:div {}])) "

"))
+    (is (= (html-str [:div {}]) "

")))
   (testing "tag with populated attribute map"
-    (is (= (html-str [:div {:min "1", :max "2"}])) "

")
-    (is (= (html-str [:img {"id" "foo"}])) "")
-    (is (= (html-str [:img {:id "foo"}])) "")
+    (is (= (html-str [:div {:min "1", :max "2"}]) "

"))
+    (is (= (html-str [:img {"id" "foo"}]) ""))
+    (is (= (html-str [:img {:id "foo"}]) ""))
     ;; (is (= (html [:img {'id "foo"}]) ""))
     ;; (is (= (html [:div {:a "1", 'b "2", "c" "3"}])
     ;;        "
"))
     )
   (testing "attribute values are escaped"
-    (is (= (html-str [:div {:id "\""}])) "

"))
+    (is (= (html-str [:div {:id "\""}]) "

")))
   (testing "boolean attributes"
-    (is (= (html-str [:input {:type "checkbox" :checked true}])) "<input checked=\"true\" type=\"checkbox\">")
-    (is (= (html-str [:input {:type "checkbox" :checked false}])) "<input type=\"checkbox\">"))
+    (is (= (html-str [:input {:type "checkbox" :checked true}]) "<input type=\"checkbox\" checked=\"true\">"))
+    (is (= (html-str [:input {:type "checkbox" :checked false}]) "<input type=\"checkbox\">")))
   (testing "nil attributes"
-    (is (= (html-str [:span {:class nil} "foo"])) "foo")))
+    (is (= (html-str [:span {:class nil} "foo"]) "foo"))))

 (deftest compiled-tags
   (testing "tag content can be vars"
     (let [x "foo"]
-      (is (= (html-str [:span x])) "foo")))
+      (is (= (html-str [:span x]) "foo"))))
   (testing "tag content can be forms"
-    (is (= (html-str [:span (str (+ 1 1))])) "2")
-    (is (= (html-str [:span ({:foo "bar"} :foo)])) "bar"))
+    (is (= (html-str [:span (str (+ 1 1))]) "2"))
+    (is (= (html-str [:span ({:foo "bar"} :foo)]) "bar")))
   (testing "attributes can contain vars"
     (let [id "id"]
-      (is (= (html-str [:div {:id id}])) "

")
-      (is (= (html-str [:div {id "id"}])) "

")
-      (is (= (html-str [:div {:id id} "bar"])) "
bar
")))
+      (is (= (html-str [:div {:id id}]) "

"))
+      (is (= (html-str [:div {id "id"}]) "

"))
+      (is (= (html-str [:div {:id id} "bar"]) "
bar
"))))
   (testing "attributes are evaluated"
-    (is (= (html-str [:img {:src (str "/foo" "/bar")}])) "")
-    (is (= (html-str [:div {:id (str "a" "b")} (str "foo")])) "
foo
"))
+    (is (= (html-str [:img {:src (str "/foo" "/bar")}]) ""))
+    (is (= (html-str [:div {:id (str "a" "b")} (str "foo")]) "
foo
")))
   ;; (testing "type hints"
   ;;   (let [string "x"]
   ;;     (are-html-rendered
   ;;      [:span ^String string] "x")))
   (testing "optimized forms"
-    (is (= (html-str [:ul (for [n (range 3)] [:li n])])) "

0

1

2

")
+    (is (= (html-str [:ul (for [n (range 3)] [:li n])]) "

0

1

2

"))
     ;; (is (= (html [:div (if true
     ;;                      [:span "foo"]
     ;;                      [:span "bar"])])


use `(name symb)` instead of `(format "%s" symb)`

--- src/metabase/api/common.clj
+++ src/metabase/api/common.clj
@@ -322,7 +322,7 @@
   "Param may not be `nil`."
   [symb value]
   (when-not value
-    (throw (ApiFieldValidationException. (format "%s" symb) "field is a required param.")))
+    (throw (ApiFieldValidationException. (name symb) "field is a required param.")))
   value)

 (defannotation Date
@@ -331,7 +331,7 @@
   [symb value :nillable]
   (try (u/parse-iso8601 value)
           (catch Throwable _
-            (throw (ApiFieldValidationException. (format "%s" symb) (format "'%s' is not a valid date." value))))))
+            (throw (ApiFieldValidationException. (name symb) (format "'%s' is not a valid date." value))))))

 (defannotation String->Integer
   "Param is converted from a string to an integer."


More missing files

More missing files

error: pathspec 'src/circleci/backend/action/junit.clj' did not match any file(s) known to git

--- src/circleci/backend/action/junit.clj
+++ src/circleci/backend/action/junit.clj
@@ -0,0 +1,21 @@
+(ns circleci.backend.action.junit
+  (:require [circleci.backend.action :as action])
+  (:require [circleci.backend.action.transfer :as transfer]))
+
+(defn with-junit [action junit-path]
+  (update-in action [:act-fn] (constantly
+                               (fn [context]
+                                 (if-let [resp (-> action :act-fn (.invoke context))]
+                                   (if (action/continue? resp)
+
+                                     resp))))))
+
+(defn junit [junit-path]
+  (action/action
+   :act-fn (fn [context]
+             (transfer/get-files context
+                                 (transfer/find-files context
+                                                      circleci.backend.action.bash/*pwd*
+                                                      junit-path)
+                                 (fn [instream]
+                                   (println "with-junit:" (slurp instream)))))))


add bench

add bench

error: pathspec 'src/main/bench/pjson/number_bench.clj' did not match any file(s) known to git

--- src/main/bench/pjson/number_bench.clj
+++ src/main/bench/pjson/number_bench.clj
@@ -0,0 +1,24 @@
+ (ns pjson.number-bench
+     (:import (pjson NumberUtil))
+     (:use perforate.core))
+
+(defn number->str [n]
+      (apply str (take n (apply str (take n (range 1 (inc n)))))))
+
+(defonce iter 1000)
+(defgoal number-parse "Number parse Benchmark"
+         :setup (fn [] (let [s (number->str 5)]
+                            [(.toCharArray s) s (count s)])))
+
+
+(defn parse5 [^chars ch]
+      (NumberUtil/parse_5 ch (int 0)))
+
+
+(defn valueOf [^String s]
+      (Long/valueOf s))
+
+
+(defcase number-parse :number-util-5 [^chars ch s l] (parse5 ch))
+
+(defcase number-parse :integer [_ ^String s l] (valueOf s))


add emit-form pass

add emit-form pass

error: pathspec 'src/main/clojure/clojure/tools/analyzer/passes/js/emit_form.clj' did not match any file(s) known to git

--- src/main/clojure/clojure/tools/analyzer/passes/js/emit_form.clj
+++ src/main/clojure/clojure/tools/analyzer/passes/js/emit_form.clj
@@ -0,0 +1,82 @@
+;;   Copyright (c) Nicola Mometto, Rich Hickey & contributors.
+;;   The use and distribution terms for this software are covered by the
+;;   Eclipse Public License 1.0 (http://opensource.org/licenses/eclipse-1.0.php)
+;;   which can be found in the file epl-v10.html at the root of this distribution.
+;;   By using this software in any fashion, you are agreeing to be bound by
+;;   the terms of this license.
+;;   You must not remove this notice, or any other, from this software.
+
+(ns clojure.tools.analyzer.passes.js.emit-form
+  (:require [clojure.tools.analyzer.passes.emit-form :as default]
+            [clojure.string :as s]
+            [cljs.tagged-literals :refer [->JSValue]])
+  (:import cljs.tagged_literals.JSValue
+           java.io.Writer))
+
+(defmulti -emit-form (fn [{:keys [op]} _] op))
+
+(defn -emit-form*
+  [{:keys [form] :as ast} opts]
+  (let [expr (-emit-form ast opts)]
+    (if-let [m (and (instance? clojure.lang.IObj expr)
+                    (meta form))]
+      (with-meta expr (merge (meta expr) m))
+      expr)))
+
+(defn emit-form
+  "Return the form represented by the given AST
+   Opts is a set of options, valid options are:
+    * :hygienic
+    * :qualified-symbols"
+  ([ast] (emit-form ast #{}))
+  ([ast opts]
+     (binding [default/-emit-form* -emit-form*]
+       (-emit-form* ast opts))))
+
+(defn emit-hygienic-form
+  "Return an hygienic form represented by the given AST"
+  [ast]
+  (binding [default/-emit-form* -emit-form*]
+    (-emit-form* ast #{:hygienic})))
+
+(defmethod -emit-form :default
+  [ast opts]
+  (default/-emit-form ast opts))
+
+(defmethod -emit-form :js
+  [{:keys [segs args]} opts]
+  (list* 'js* (s/join "~{}" segs) (mapv #(-emit-form* % opts) args)))
+
+(defmethod -emit-form :js-object
+  [{:keys [keys vals]} opts]
+  (->JSValue (zipmap (map #(-emit-form* % opts) keys)
+                     (map #(-emit-form* % opts) vals))))
+
+(defmethod -emit-form :js-array
+  [{:keys [keys vals]} opts]
+  (->JSValue (zipmap (map #(-emit-form* % opts) keys)
+                     (map #(-emit-form* % opts) vals))))
+
+(defmethod print-method JSValue [^JSValue o ^Writer w]
+  (.write w "#js ")
+  (.write w (str (.val o))))
+
+(defmethod -emit-form :deftype
+  [{:keys [name fields pmask body]} opts]
+  (list 'deftype* name (map #(-emit-form* % opts) fields) pmask
+        (-emit-form* body opts)))
+
+(defmethod -emit-form :defrecord
+  [{:keys [name fields pmask body]} opts]
+  (list 'defrecord* name (map #(-emit-form* % opts) fields) pmask
+        (-emit-form* body opts)))
+
+(defmethod -emit-form :case
+  [{:keys [test nodes default]} opts]
+  `(case* ~(-emit-form* test opts)
+          ~@(reduce (fn [acc {:keys [tests then]}]
+                      (-> acc
+                        (update-in 0 conj (mapv #(-emit-form* (:test %) opts) tests))
+                        (update-in 1 conj (-emit-form* then opts))))
+                    [[] []] nodes)
+          ~(-emit-form* default opts)))


Bring Clojure client in line with contract

--- clojure/httpkit/src/websocket/server.clj
+++ clojure/httpkit/src/websocket/server.clj
@@ -15,12 +15,13 @@
   (log/info "channel closed:" status)
   (swap! channels disj channel))

-(defn broadcast [_ msg]
+(defn broadcast [ch payload]
   (doseq [channel @channels]
-    (send! channel msg)))
+    (send! channel (json/encode {:type "broadcast" :payload payload})))
+  (send! ch (json/encode {:type "broadcastResult" :payload payload})))

-(defn echo [ch msg]
-  (send! ch msg))
+(defn echo [ch payload]
+  (send! ch (json/encode {:type "echo" :payload payload})))

 (defn unknown-type-response [ch _]
   (send! ch (json/encode {:type "error" :payload "ERROR: unknown message type"})))
@@ -31,7 +32,7 @@
         "echo" echo
         "broadcast" broadcast
         unknown-type-response)
-      ch msg)))
+      ch (get parsed "payload"))))

 (defn ws-handler [request]
   (with-channel request channel


Add tests for atom feeds.

Add tests for atom feeds.

Relates to #72.

error: pathspec 'test/statuses/views/test/atom.clj' did not match any file(s) known to git

--- test/statuses/views/test/atom.clj
+++ test/statuses/views/test/atom.clj
@@ -0,0 +1,88 @@
+(ns statuses.views.test.atom
+  (:require [clj-time.core :refer [date-time]]
+            [clojure.test :refer [deftest is]]
+            [statuses.views.atom :refer [feed]]))
+
+(defn- as-uri
+  "Returns a java.net.URI from the given string"
+  [uri]
+  (java.net.URI/create uri))
+
+(defn- feed-with
+  "Returns a feed with the given entries"
+  [entries]
+  (feed entries "http://localhost:8080" "/statuses/updates"))
+
+(defn- feed-with-entry
+  "Creates a new feed with one entry from the given entry template."
+  [entry-template]
+  (feed-with [(merge
+                {:id 0, :author "", :text "", :time (date-time 2000 1 1 0 0 0 0)}
+                entry-template)]))
+
+(deftest test-feed
+  (let [feed (feed-with [{:time (date-time 2014 11 20 9 39 30 001)}])]
+    (is (= (get feed 2)
+           [:title "innoQ Status updates"])
+        "feed title is: innoQ Status updates")
+
+    (is (= (get feed 3)
+           [:id "http://localhost:8080/statuses/updates"])
+           ;[:id "http://localhost:8080/statuses/updates?format=atom"]) ???
+        "feed id is uri of feed")
+
+    (is (= (get feed 4)
+           [:updated "2014-11-20T09:39:30Z"])
+           ;[:updated "2014-11-20T09:39:30.001Z"]) ???
+        "feed updated is in rfc3339 format: yyyy-MM-dd'T'hh:mm:ss'Z'")
+
+    (is (= (get feed 5)
+           [:link {:rel "self"
+                   :href "http://localhost:8080/statuses/updates"
+                   ;:href "http://localhost:8080/statuses/updates?format=atom" ???
+                   :type "application/atom+xml"}])
+        "feed self link is atom type and points to feed uri")
+
+    (is (= (get feed 6)
+           [:author
+            [:name "innoQ"]
+            [:uri "http://localhost:8080"]])
+            ;[:uri "http://localhost:8080/statuses/updates"]]) ???
+        "feed author has name and correct uri")))
+
+(deftest test-feed-entry
+  (letfn [(entry[feed] (get feed 7))]
+    (is (= (get (entry (feed-with-entry {:author "bar"})) 1)
+           [:title "Posted by @bar"])
+      "title is: Posted by @author")
+
+    (is (= (get (entry (feed-with-entry {:author "bar"})) 2)
+           [:author
+            [:name "bar"]
+            [:uri [:a {:href (as-uri "http://localhost:8080?author=bar")} ["bar"]]]])
+            ;[:uri "http://localhost:8080/statuses/updates?author=bar"]]) ???
+      "author contains correct name and uri")
+
+    (is (= (get (entry (feed-with-entry {:text "@bar: http://www.test.de"})) 3)
+           [:content {:type "html"}
+            "@bar: http://www.test.de"])
+      "content is linkified and escaped")
+
+    (is (= (get (entry (feed-with-entry {:id 1337})) 4)
+           [:id "tag:innoq.com,2012:statuses/1337"])
+      "id is 'tag:innoq.com,2012:statuses/id'")
+
+    (is (= (get (entry (feed-with-entry {:time (date-time 2014 11 20 9 39 30 001)})) 5)
+           [:published "2014-11-20T09:39:30Z"])
+           ;[:published "2014-11-20T09:39:30.001Z"]) ???
+      "published is in rfc3339 format: yyyy-MM-dd'T'hh:mm:ss'Z'")
+
+    (is (= (get (entry (feed-with-entry {:time (date-time 2014 11 20 9 39 30 001)})) 6)
+           [:updated "2014-11-20T09:39:30Z"])
+           ;[:updated "2014-11-20T09:39:30.001Z"]) ???
+      "updated is in rfc3339 format: yyyy-MM-dd'T'hh:mm:ss'Z'")
+
+    (is (= (get (entry (feed-with-entry {:id 1337})) 7)
+           [:link {:href "http://localhost:8080/statuses/updates/1337"}])
+      "link points to correct status")))
+


[EN] Refactoring.

[EN] Refactoring.

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/democracyworks/form-works.git/'


Added demo custom tag for testing purposes.

error: pathspec 'src/dragon/selmer/tags/demo.clj' did not match any file(s) known to git

--- src/dragon/selmer/tags/demo.clj
+++ src/dragon/selmer/tags/demo.clj
@@ -0,0 +1,5 @@
+(ns dragon.selmer.tags.demo
+  (:require [clojure.string :as string]))
+
+(defn foo-tag [args context-map]
+  (str "foo " (first args)))


one more

one more

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/jeelabs/jet.git/'


Only recalculate quad-tree on demand. Takes perf from ~9fps to ~40fps.

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/cstorey/nrod.git/'


bump deps

bump deps

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/jtbeckha/alda.git/'


Add inline date picker to step logistics.move-in-date/choose-date

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/starcity-properties/odin.git/'


fix permissions checking in GET /api/dash

--- src/metabase/api/dash.clj
+++ src/metabase/api/dash.clj
@@ -1,11 +1,13 @@
 (ns metabase.api.dash
   "/api/meta/dash endpoints."
   (:require [compojure.core :refer [GET POST PUT DELETE]]
+            [korma.core :refer :all]
             [medley.core :as medley]
             [metabase.api.common :refer :all]
             [metabase.db :refer :all]
             (metabase.models [hydrate :refer [hydrate]]
                              [card :refer [Card]]
+                             [common :as common]
                              [dashboard :refer [Dashboard]]
                              [dashboard-card :refer [DashboardCard]]
                              [org :refer [Org]])
@@ -20,7 +22,8 @@
   {org Required, f FilterOptionAllOrMine}
   (read-check Org org)
   (-> (case (or f :all)
-        :all  (sel :many Dashboard :organization_id org)
+        :all  (sel :many Dashboard :organization_id org (where (or {:creator_id *current-user-id*}
+                                                                   {:public_perms [> common/perms-none]})))
         :mine (sel :many Dashboard :organization_id org :creator_id *current-user-id*))
       (hydrate :creator :organization)))


add rules file with score

add rules file with score

error: pathspec 'src/client/rules.cljs' did not match any file(s) known to git

--- src/client/rules.cljs
+++ src/client/rules.cljs
@@ -0,0 +1,10 @@
+(ns client.rules)
+
+(defn get-points
+  "Determine how many points were scored."
+  [rows-cleared]
+  (case rows-cleared
+    1 (* 40 rows-cleared)
+    2 (* 100 rows-cleared)
+    3 (* 300 rows-cleared)
+    4 (* 1200 rows-cleared)))


Trying again

Trying again

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/physion/ovation-webapi.git/'


Separate expected-failing and -passing concerns.

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/croeder/clojure-koans-work.git/'


Fix drop-leading-star typo

Fix drop-leading-star typo

--- src/clj/clojuredocs/search.clj
+++ src/clj/clojuredocs/search.clj
@@ -183,7 +183,7 @@

 (defn format-query [q]
   (-> q
-      drop-leading-star
+      drop-leading-stars
       str/trim
       lucene-escape
       (str "*")))


Trello code

Trello code

error: pathspec 'src/clj/new_website/trello.clj' did not match any file(s) known to git

--- src/clj/new_website/trello.clj
+++ src/clj/new_website/trello.clj
@@ -0,0 +1,28 @@
+(ns new-website.trello
+  (:require [environ.core :as environ]
+            [compojure.core :refer [POST defroutes]]
+            [clj-http.client :as client]))
+
+(defn- post-card [req]
+  (let [api-endpoint "https://api.trello.com"
+        api-version 1
+        params (:params req)
+        target-list "56e0e91ed298192e73abd2a8"
+        meeting-label "56e0e910152c3f92fd5b8e13"
+        name (if (empty? (:name params))
+                "Schedule a meeting"
+                (str "Schedule a meeting with " (:name params)))
+        desc (:description params)
+        resp (client/post (str api-endpoint "/" api-version "/cards")
+              {:query-params
+                {:token (environ/env :trello-api-token)
+                 :key (environ/env :trello-api-key)
+                 :idList target-list
+                 :idLabels [meeting-label]
+                 :pos "top"
+                 :name name
+                 :desc desc}})]
+    {:status 200 :body (str resp)}))
+
+(defroutes trello-routes
+  (POST "/create-card" [req] post-card))


Add popover src file

Add popover src file

error: pathspec 'src/cljc/robinson/popover.cljc' did not match any file(s) known to git

--- src/cljc/robinson/popover.cljc
+++ src/cljc/robinson/popover.cljc
@@ -0,0 +1,36 @@
+;; Functions that manipulate state when showing popovers
+(ns robinson.popover
+  (:require
+            [robinson.common :as rc]
+            [robinson.random :as rr]
+            [robinson.world :as rw]
+            robinson.macros
+            #?@(:clj (
+                [robinson.macros :as rm]
+                [taoensso.timbre :as log])
+                :cljs (
+                [robinson.macros :as rm :include-macros true]
+                [taoensso.timbre :as log :include-macros true]))))
+
+
+(defn show-popover
+  ([state message]
+    (show-popover state message :normal))
+  ([state message next-state]
+  (-> state
+    (rw/assoc-current-state :popover)
+    (assoc-in [:world :popover-message] message)
+    (assoc-in [:world :next-state] next-state))))
+
+(defn clear-popover
+  [state]
+  (rc/dissoc-in state [:world :popover-message]))
+
+(defn get-popover-message
+  [state]
+  (get-in state [:world :popover-message]))
+
+(defn get-popover-next-state
+  [state]
+  (get-in state [:world :next-state]))
+


title now editable, reverse date sorting added

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/talexand/velcro-notes.git/'


Add old 0.1.x API as deprecated functions

error: pathspec 'src/main/clojure/clojure/tools/namespace.clj' did not match any file(s) known to git

--- src/main/clojure/clojure/tools/namespace.clj
+++ src/main/clojure/clojure/tools/namespace.clj
@@ -0,0 +1,196 @@
+ ;; Copyright (c) Stuart Sierra, 2012. All rights reserved.  The use
+ ;; and distribution terms for this software are covered by the Eclipse
+ ;; Public License 1.0 (http://opensource.org/licenses/eclipse-1.0.php)
+ ;; which can be found in the file epl-v10.html at the root of this
+ ;; distribution.  By using this software in any fashion, you are
+ ;; agreeing to be bound by the terms of this license.  You must not
+ ;; remove this notice, or any other, from this software.
+
+(ns
+ ^{:author "Stuart Sierra",
+   :doc "This namespace is DEPRECATED; most functions have been moved to
+  other namespaces"}
+ clojure.tools.namespace
+ (:require [clojure.java.io :as io])
+ (:import (java.io File FileReader BufferedReader PushbackReader
+                   InputStreamReader)
+          (java.util.jar JarFile JarEntry)))
+
+
+;;; Finding namespaces in a directory tree
+
+(defn clojure-source-file?
+  "DEPRECATED; trivial to implement locally
+
+  Returns true if file is a normal file with a .clj extension."
+  [^File file]
+  (and (.isFile file)
+       (.endsWith (.getName file) ".clj")))
+
+(defn find-clojure-sources-in-dir
+  "DEPRECATED; moved to clojure.tools.namespace.find
+
+  Searches recursively under dir for Clojure source files (.clj).
+  Returns a sequence of File objects, in breadth-first sort order."
+  [^File dir]
+  ;; Use sort by absolute path to get breadth-first search.
+  (sort-by #(.getAbsolutePath ^File %)
+           (filter clojure-source-file? (file-seq dir))))
+
+(defn comment?
+  "DEPRECATED; moved to clojure.tools.namespace.parse
+
+  Returns true if form is a (comment ...)"
+  [form]
+  (and (list? form) (= 'comment (first form))))
+
+(defn ns-decl?
+  "DEPRECATED; moved to clojure.tools.namespace.parse
+
+  Returns true if form is a (ns ...) declaration."
+  [form]
+  (and (list? form) (= 'ns (first form))))
+
+(defn read-ns-decl
+  "DEPRECATED; moved to clojure.tools.namespace.parse
+
+  Attempts to read a (ns ...) declaration from rdr, and returns the
+  unevaluated form.  Returns nil if read fails or if a ns declaration
+  cannot be found.  The ns declaration must be the first Clojure form
+  in the file, except for (comment ...)  forms."
+  [^PushbackReader rdr]
+  (try
+   (loop [] (let [form (doto (read rdr) str)]
+              (cond
+               (ns-decl? form) form
+               (comment? form) (recur)
+               :else nil)))
+       (catch Exception e nil)))
+
+(defn read-file-ns-decl
+  "DEPRECATED; moved to clojure.tools.namespace.file
+
+  Attempts to read a (ns ...) declaration from file, and returns the
+  unevaluated form.  Returns nil if read fails, or if the first form
+  is not a ns declaration."
+  [^File file]
+  (with-open [rdr (PushbackReader. (BufferedReader. (FileReader. file)))]
+    (read-ns-decl rdr)))
+
+(defn find-ns-decls-in-dir
+  "DEPRECATED; moved to clojure.tools.namespace.find
+
+  Searches dir recursively for (ns ...) declarations in Clojure
+  source files; returns the unevaluated ns declarations."
+  [^File dir]
+  (filter identity (map read-file-ns-decl (find-clojure-sources-in-dir dir))))
+
+(defn find-namespaces-in-dir
+  "DEPRECATED; moved to clojure.tools.namespace.find
+
+  Searches dir recursively for (ns ...) declarations in Clojure
+  source files; returns the symbol names of the declared namespaces."
+  [^File dir]
+  (map second (find-ns-decls-in-dir dir)))
+
+;;; copied from clojure.java.classpath to preserve deprecated API
+;;; without an explicit dependency
+
+(defn- loader-classpath [loader]
+  (when (instance? java.net.URLClassLoader loader)
+    (map
+     #(java.io.File. (.getPath ^java.net.URL %))
+     (.getURLs ^java.net.URLClassLoader loader))))
+
+(defn- classpath
+  ([classloader]
+     (distinct
+      (mapcat
+       loader-classpath
+       (take-while
+        identity
+        (iterate #(.getParent %) classloader)))))
+  ([] (classpath (clojure.lang.RT/baseLoader))))
+
+(defn- classpath-directories []
+  (filter #(.isDirectory ^File %) (classpath)))
+
+(defn- jar-file? [f]
+  (let [file (io/file f)]
+    (and (.isFile file)
+         (or (.endsWith (.getName file) ".jar")
+             (.endsWith (.getName file) ".JAR")))))
+
+(defn- classpath-jarfiles []
+  (map #(JarFile. ^File %) (filter jar-file? (classpath))))
+
+(defn- filenames-in-jar [^JarFile jar-file]
+  (map #(.getName ^JarEntry %)
+       (filter #(not (.isDirectory ^JarEntry %))
+               (enumeration-seq (.entries jar-file)))))
+
+;;; Finding namespaces in JAR files
+
+(defn clojure-sources-in-jar
+  "DEPRECATED; moved to clojure.tools.namespace.find
+
+  Returns a sequence of filenames ending in .clj found in the JAR file."
+  [^JarFile jar-file]
+  (filter #(.endsWith ^String % ".clj") (filenames-in-jar jar-file)))
+
+(defn read-ns-decl-from-jarfile-entry
+  "DEPRECATED; moved to clojure.tools.namespace.find
+
+  Attempts to read a (ns ...) declaration from the named entry in the
+  JAR file, and returns the unevaluated form.  Returns nil if the read
+  fails, or if the first form is not a ns declaration."
+  [^JarFile jarfile ^String entry-name]
+  (with-open [rdr (PushbackReader.
+                   (BufferedReader.
+                    (InputStreamReader.
+                     (.getInputStream jarfile (.getEntry jarfile entry-name)))))]
+    (read-ns-decl rdr)))
+
+(defn find-ns-decls-in-jarfile
+  "DEPRECATED; moved to clojure.tools.namespace.find
+
+  Searches the JAR file for Clojure source files containing (ns ...)
+  declarations; returns the unevaluated ns declarations."
+  [^JarFile jarfile]
+  (filter identity
+          (map #(read-ns-decl-from-jarfile-entry jarfile %)
+               (clojure-sources-in-jar jarfile))))
+
+(defn find-namespaces-in-jarfile
+  "DEPRECATED; moved to clojure.tools.namespace.find
+
+  Searches the JAR file for Clojure source files containing (ns ...)
+  declarations.  Returns a sequence of the symbol names of the
+  declared namespaces."
+  [^JarFile jarfile]
+  (map second (find-ns-decls-in-jarfile jarfile)))
+
+;;; Finding namespaces anywhere on CLASSPATH
+
+(defn find-ns-decls-on-classpath
+  "DEPRECATED; use clojure.tools.namespace.find/find-ns-decls
+  and clojure.java.classpath/classpath from
+  http://github.com/clojure/java.classpath
+
+  Searches CLASSPATH (both directories and JAR files) for Clojure
+  source files containing (ns ...) declarations. Returns a sequence of
+  the unevaluated ns declaration forms." []
+  (concat
+   (mapcat find-ns-decls-in-dir (classpath-directories))
+   (mapcat find-ns-decls-in-jarfile (classpath-jarfiles))))
+
+(defn find-namespaces-on-classpath
+  "DEPRECATED; use clojure.tools.namespace.find/find-namespaces
+  and clojure.java.classpath/classpath from
+  http://github.com/clojure/java.classpath
+
+  Searches CLASSPATH (both directories and JAR files) for Clojure
+  source files containing (ns ...) declarations.  Returns a sequence
+  of the symbol names of the declared namespaces."
+  []
+  (map second (find-ns-decls-on-classpath)))


Add mapping for reg-methods API

Add mapping for reg-methods API

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/democracyworks/turbovote-http-api.git/'


def.. -> setup-..

def.. -> setup-..

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/michaelsbradleyjr/transwarp.git/'


formatting

formatting


views: add core.async

views: add core.async

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/pyr/bundes.git/'


initial commit on context print

initial commit on context print

error: pathspec 'src/strictly_specking/context_print.clj' did not match any file(s) known to git

--- src/strictly_specking/context_print.clj
+++ src/strictly_specking/context_print.clj
@@ -0,0 +1,311 @@
+(ns strictly-specking.context-print
+  (:require
+   [clojure.java.io :as io]
+   [clojure.zip :as zip]
+   [clojure.string :as string]
+   [net.cgrand.sjacket :as sj]
+   [net.cgrand.sjacket.parser :as p]))
+
+(defn- at-newline? [loc]
+  (= :newline (:tag (zip/node loc))))
+
+(defn line-number-of [root-zip l]
+  (let [node (zip/node l)]
+    (loop [c 1
+           loc root-zip]
+      (if (= (zip/node loc) node)
+        c
+        (recur
+         (if (at-newline? loc) (inc c) c)
+         (zip/next loc))))))
+
+(def line-number (partial #'line-number-of z))
+
+(defn node-test [tag n]
+  (and (map? n)
+       (= (:tag n) tag)))
+
+(def keyword-node? (partial node-test :keyword))
+(def map-node?     (partial node-test :map))
+(def set-node?     (partial node-test :set))
+(def list-node?    (partial node-test :list))
+(def vector-node?  (partial node-test :vector))
+(def coll-node?    (some-fn map-node? list-node? vector-node?))
+(def name-node?    (partial node-test :name))
+(def symbol-node?  (partial node-test :symbol))
+
+(defn is-keyword? [k n]
+  (and (keyword-node? n)
+       (= (get-in n [:content 1 :content])
+          [(name k)])))
+
+(defn is-project? [n]
+  (and (name-node? n)
+       (= (:content n)
+          ["defproject"])))
+
+(defn node [loc]
+  (and loc
+       (zip/node loc)))
+
+#_(is-keyword? :description
+             {:tag :keyword, :content [":" {:tag :name, :content ["description"]}]})
+
+(defn- insignificant? [loc]
+  (when-let [{:keys [tag]} (zip/node loc)]
+    (p/space-nodes tag)))
+
+(defn- find-first [pred loc]
+  (->> loc
+       (iterate zip/next)
+       (take-while (comp not zip/end?))
+       (filter (comp pred zip/node))
+       first))
+
+(defn find-project [loc]
+  (->> loc
+       (find-first is-project?)
+       zip/up))
+
+(defn lazy-right-list [loc]
+  (->> loc
+       (iterate zip/right)
+       (take-while (comp not nil?))
+       (remove insignificant?)))
+
+(defn find-key-in-structure [k loc]
+  (->> loc
+       lazy-right-list
+       (drop 1)
+       (partition 2)
+       (map first)
+       (filter (comp (partial is-keyword? k) zip/node))
+       first))
+
+(defn- find-key-in-project [k loc]
+  (->> loc
+       find-project
+       (find-key-in-structure k)))
+
+(defn find-key-in-map [k loc]
+  (assert (map-node? (zip/node loc)) "Must be a map node.")
+  (->> loc
+       zip/down
+       (find-key-in-structure k)))
+
+(defn find-key-in-seq [k loc]
+  (assert (integer? k) "Key to seq must be integer.")
+  (->> loc
+       zip/down
+       lazy-right-list
+       (drop 1)
+       (drop k)
+       first))
+
+(defn project-node? [n]
+      (and (symbol-node? n)
+           (->> n :content first is-project?)))
+
+(defn- next-value [loc]
+  (->> loc
+       lazy-right-list
+       (drop 1)
+       first))
+
+(defn find-key-in-node [k loc]
+  (when-let [n (zip/node loc)]
+    (cond
+      (project-node? n) (find-key-in-project k loc)
+      (map-node? n)     (find-key-in-map k loc)
+      (vector-node? n)  (find-key-in-seq k loc)
+      (list-node? n)    (find-key-in-seq k loc)
+      ;; TODO sets
+      :else nil)))
+
+(defn find-key-value-in-node [k loc]
+  (when-let [res (find-key-in-node k loc)]
+    (let [n (zip/node loc)]
+      (cond
+        (project-node? n) (next-value res)
+        (map-node? n)     (next-value res)
+        :else res))))
+
+(defn get-value-at-path
+  "given a path into a structure return its location"
+  [path loc]
+  (reduce #(find-key-value-in-node %2 %1) loc (butlast path)))
+
+(defn get-loc-at-path
+  "given a path into a structure return its location"
+  [path loc]
+  (when-let [value-above (get-value-at-path path loc)]
+    (find-key-in-node (last path) value-above)))
+
+(defn file-to-parsed-zipper [file]
+  (when (.exists (io/file file))
+    (-> (io/file file)
+        slurp
+        p/parser
+        zip/xml-zip)))
+
+(defn file-to-initial-position [file]
+  (when-let [loc (file-to-parsed-zipper file)]
+    (if (= "project.clj" (.getName (io/file file)))
+      (find-project loc)
+      (find-first coll-node? loc))))
+
+(defn- sjacket->clj [value]
+  (try
+    (if-not (#{:comment :whitespace :newline} (:tag value))
+      (-> value sj/str-pt read-string))
+    (catch Throwable e
+      nil)))
+
+(defn get-path-in-clj-file
+  "Given the name of a file that holds a collection of EDN data or
+   a project.clj file. This function will traverse the given path and
+   return a map of the following info:
+
+     :line - the line number where the found item
+     :column - the column number of the found item
+     :value  - the value of the found item
+     :path   - the path that was supplied as an argument
+     :loc    - the zipper at this point
+
+   There is some ambiguity around whether this represents a key and a
+   value or just a value at a point.  If the last key is a member of a
+   map, the value returned will be the value at the key position.
+   Otherwise, the value at the position itself will be returned.
+"
+
+  [path file]
+  (when-let [loc (file-to-initial-position file)]
+    (when-let [point-loc (get-loc-at-path path loc)]
+      {:line (line-number point-loc)
+       :column (sj/column point-loc)
+       :file file
+       :value  (or (sjacket->clj (-> point-loc next-value zip/node))
+                   (sjacket->clj (zip/node point-loc)))
+       :path path
+       ; :loc point-loc
+       })))
+
+
+;; displaying error in context of file
+
+(defn fetch-lines [file]
+  (let [file (io/file file)]
+    (when (.exists file)
+      (doall (line-seq (io/reader file))))))
+
+(defn number-lines [lines]
+  (map-indexed #(vector :line (inc %1)
+                        %2) lines))
+
+(defn blanks [n]
+  (apply str (repeat n " ")))
+
+(defn format-message [column msg]
+  (let [lines   (string/split msg #"\n")
+        prefix        (blanks column)
+        prefix-indent (str prefix (blanks 6))]
+    (->> (rest lines)
+         (map #(str prefix-indent %))
+         (string/join "\n")
+         (str prefix "^---  " (first lines) "\n"))))
+
+(defn insert-message [numbered-lines line column message]
+  (concat
+   (take-while #(not= (second %) line) numbered-lines)
+   [[:error-line line (last (nth numbered-lines (dec line)))]]
+   [[:message-line nil (format-message column message)]]
+   (drop-while #(not= (second %)
+                      (inc line)) numbered-lines)))
+
+(defn extract-range [formatted-lines center half-range]
+  (filter
+   #(let [[_ a _] %]
+      (or (nil? a)
+          (< (- center half-range) a (+ center half-range))))
+   formatted-lines))
+
+(defn max-line-number [formatted-lines]
+  (-> formatted-lines
+      (map second)
+      (filter number?)
+      (reduce max)))
+
+(defn min-blank-lead [formatted-lines]
+  (->> formatted-lines
+       (map last)
+       (filter (complement string/blank?))
+       (map #(count (take-while #{\space} %)))
+       (reduce min)))
+
+(defn blank-space-trim [formatted-lines]
+  (let [min-lead (min-blank-lead formatted-lines)]
+    (when (> min-lead 6)
+      (let [subtract-lead (- min-lead 6)]
+        (map (fn [[t l b]]
+               [t l (if (string/blank? b)
+                      b
+                      (subs b subtract-lead))])
+             formatted-lines)))))
+
+(defn print-formatted-lines [formatted-lines]
+  (let [max-char-length (+ 2 (count (str (max-line-number formatted-lines))))]
+    (doseq [[t l b] formatted-lines]
+      (condp = t
+        :line
+        (println (str (format (str "%" max-char-length "d ") l) b))
+        :error-line
+        (println (str (format (str "%" max-char-length "d ") l) b))
+        :message-line
+        (doseq [b (string/split b #"\n")]
+          (println (str (blanks (inc max-char-length))
+                        b)))))))
+
+#_(mapv println (map last
+
+                   (-> (fetch-lines "project.clj")
+                       number-lines
+                       (insert-message 35 28 "here I am \nonce again \nonce again  \nonce again again")
+                       (extract-range 35 10)
+                       blank-space-trim
+                       print-formatted-lines
+                       )
+
+                   )
+      )
+
+
+#_(slurp (io/file "project.clj"))
+
+
+
+#_(get-path-in-clj-file [:cljsbuild :builds 1 :figwheel :debug] "test.edn")
+
+
+#_(find-project z)
+
+#_(->> edn
+       (find-first coll-node?)
+       (get-value-at-path [:cljsbuild :builds])
+       #_(find-key-value-in-node :cljsbuild)
+       #_(find-key-value-in-node :builds)
+       #_(find-key-value-in-node 0)
+       #_(find-key-in-node :id)
+       (get-loc-at-path [:cljsbuild :builds])
+
+       #_(get-loc-at-path [:cljsbuild :builds ])
+       )
+
+#_(-> z
+     find-project
+     (get-loc-at-path [:cljsbuild :builds 1 :id])
+
+    ((juxt
+      line-number
+      sj/column)))
+
+


Allow specification of output directory.


util/s3.clj: started interface to S3

util/s3.clj: started interface to S3

error: pathspec 'src/org/altlaw/util/s3.clj' did not match any file(s) known to git

--- src/org/altlaw/util/s3.clj
+++ src/org/altlaw/util/s3.clj
@@ -0,0 +1,43 @@
+(ns org.altlaw.util.s3
+  (:import (org.jets3t.service.impl.rest.httpclient RestS3Service)
+           (org.jets3t.service.model S3Bucket S3Object)
+           (org.jets3t.service.security AWSCredentials)))
+
+(def #^{:private true} get-s3
+     (memoize (fn [] (RestS3Service.
+                      (AWSCredentials. (System/getenv "AWS_ACCESS_KEY_ID")
+                                       (System/getenv "AWS_SECRET_ACCESS_KEY"))))))
+
+(def #^{:private true} get-bucket
+     (memoize (fn [x]
+                (if (instance? S3Bucket x) x
+                    (.getBucket (get-s3) x)))))
+
+(defn- make-bucket-symbol [bucket]
+  (with-meta (symbol (.getName bucket))
+             (into {} (.getMetadataMap bucket))))
+
+(defn- make-object-symbol [object]
+  (with-meta (symbol (.getKey object))
+             (into {} (.getMetadataMap object))))
+
+(defn list-buckets
+  "Returns a list of symbols.  Each symbol has a name matching a
+  bucket name, and metadata matching that bucket's S3 metadata."
+  []
+  (map make-object-symbol
+       (.listAllBuckets (get-s3))))
+
+(defn list-objects
+  ([bucket-name]
+     (.listObjects (get-s3) (get-bucket bucket-name)))
+  ([bucket-name prefix]
+     (.listObjects (get-s3) (get-bucket bucket-name) nil)))
+
+(defn get-object [bucket-name object-key]
+  (.getObject (get-s3) (get-bucket bucket-name) object-key))
+
+(defn get-object-meta [bucket-name object-key]
+  (into {} (.getMetadataMap
+            (.getObjectDetails (get-s3) (get-bucket bucket-name)
+                               object-key))))


Added db queries for ragam page's data.

Added db queries for ragam page's data.

error: pathspec 'src/kosha/db/ragam.clj' did not match any file(s) known to git

--- src/kosha/db/ragam.clj
+++ src/kosha/db/ragam.clj
@@ -0,0 +1,22 @@
+(ns kosha.db.ragam
+  (:require [clojure.java.jdbc :as j]
+            [kosha.db.pool :as db-pool]
+            [kosha.db.util :as db-util]))
+
+(defn ragam
+  "Retrieves details of a ragam given it's id."
+  [ragam-id]
+  (let [q ["SELECT ragam_id, name, arohanam, avarohanam, ragam_link AS wiki_page, melakartha, mela_ragam_id, data_source
+            FROM ragams
+            WHERE ragam_id = ?; "
+           ragam-id]]
+    (first (j/query db-pool/conn q :identifier db-util/->hyphens))))
+
+(defn kritis-of-ragam
+  "Retrieves all kritis of a ragam with the given id."
+  [ragam-id]
+  (let [q ["SELECT kriti_id, name, composer, taala, language, ragam_id, url, data_source
+            FROM kritis
+            WHERE ragam_id = ?; "
+           ragam-id]]
+    (vec (j/query db-pool/conn q :identifer db-util/->hyphens))))


Note ven needed for debug.

Note ven needed for debug.

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/mtravers/incidents.git/'


Added styling for variable substitutions; substitute vars for non-manuscript text

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/hudren/ebook-novel.git/'


fix onboarding

fix onboarding


using go block

using go block


Add missing file

Add missing file

error: pathspec 'src-cljs/photon/ui/api.cljs' did not match any file(s) known to git

--- src-cljs/photon/ui/api.cljs
+++ src-cljs/photon/ui/api.cljs
@@ -0,0 +1,134 @@
+(ns photon.ui.api
+  (:require-macros [cljs.core.async.macros :refer [go]])
+  (:require [om.next :as om :refer-macros [defui]]
+            [om.dom :as dom]
+            [goog.net.cookies :as ck]
+            [photon.ui.ws :as ws]
+            [photon.ui.components :as comp]))
+
+(defui PhotonApps
+  static om/IQuery
+  (query [this] `[:security-info])
+  Object
+  (render
+   [this]
+   (let [{:keys [security-info]} (om/props this)
+         apps (vals (get (:security security-info) "admin"))
+         apps-table (map
+                     #(-> %
+                          (select-keys [:app-name :description :website])
+                          (assoc :meta/original %)
+                          (assoc :action/show-keys :action/show-keys))
+                     apps)]
+     (dom/div
+      nil
+      (dom/div
+       #js {:className "row"}
+       ((om/factory comp/FormButton)
+        {:text "Create new app"
+         :onClick
+         (fn [_]
+           (om/transact! this `[(ui/update {:k :selected-app :v nil})
+                                (ui/update {:k :new-app :v true})
+                                :ui-state]))}))
+      (dom/div
+       #js {:className "row"}
+       ((om/factory comp/Table)
+        {:data apps-table :owner this
+         :rows [:app-name :description :website :action/show-keys]}))))))
+
+(defui AppInfo
+  static om/IQuery
+  (query [this] `[:security-info])
+  Object
+  (render
+   [this]
+   (let [{:keys [ui-state security]} (:security-info (om/props this))]
+     (dom/div
+      nil
+      (dom/div
+       #js {:className "row"}
+       (if (:new-app ui-state)
+         (dom/form
+          #js {:className "form-horizontal form-label-left"
+               :onSubmit (fn [e] (.preventDefault e) false)}
+          (comp/label-input
+           {:owner this :key :aform/name
+            :val (:aform/name ui-state) :label "Name"})
+          (comp/label-input
+           {:owner this :key :aform/description
+            :val (:aform/description ui-state) :label "Description"})
+          (comp/label-input
+           {:owner this :key :aform/website
+            :val (:aform/website ui-state) :label "App website"})
+          (comp/form-button
+           {:text "Create application"
+            :onClick
+            (fn [_]
+              (go
+                (<!
+                 (ws/post-api "/auth/app"
+                              {:query-params
+                               {:name (:aform/name ui-state)
+                                :description (:aform/description ui-state)
+                                :website (:aform/website ui-state)}}))
+                (om/transact! this `[(ui/update {:k :new-app :v false})
+                                     :ui-state])))}))
+         (if-let [app (:selected-app ui-state)]
+           (dom/form
+            #js {:className "form-horizontal form-label-left"
+                 :onSubmit (fn [e] (.preventDefault e) false)}
+            (comp/label-label
+             {:label "Name" :second-label (:app-name app)})
+            (comp/label-label
+             {:label "Description" :second-label (:description app)})
+            (comp/label-label
+             {:label "Website" :second-label (:website app)})
+            (comp/label-label
+             {:label "Client ID" :second-label (str (:client-id app))})
+            (comp/label-label
+             {:label "Client secret" :second-label (str (:client-secret app))})
+            (comp/label-label
+             {:label "Test URL"
+              :second-label
+              (str "curl \"" (ck/get "server") "/api/ping?client_id="
+                   (:client-id app) "&client_secret="
+                   (:client-secret app) "\"")})
+            #_(comp/label-input
+             {:owner this :key :aform/description
+              :val (:aform/description ui-state) :label "Description"})
+            #_(comp/label-input
+             {:owner this :key :aform/website
+              :val (:aform/website ui-state) :label "App website"})
+            #_(comp/form-button
+             {:text "Create application"
+              :onClick
+              (fn [_]
+                (go
+                  (<!
+                   (ws/post-api "/auth/app"
+                                {:query-params
+                                 {:name (:aform/name ui-state)
+                                  :description (:aform/description ui-state)
+                                  :website (:aform/website ui-state)}}))
+                  (om/transact! this `[(ui/update {:k :new-app :v false})
+                                       :ui-state])))}))
+           (dom/p nil "Select and existing app or create a new one"))))))))
+
+(defui ManageKeys
+  static om/IQuery
+  (query [this] `[{:security-info ~(om/get-query AppInfo)}
+                  {:security-info ~(om/get-query PhotonApps)}])
+  Object
+  (render
+   [this]
+   (dom/div
+    #js {:className "row"}
+    ((om/factory comp/HalfPanel)
+     {:title "Photon Apps"
+      :component PhotonApps
+      :data (om/props this)})
+    ((om/factory comp/HalfPanel)
+     {:title "App Info"
+      :component AppInfo
+      :data {}}))))


Reformat: remove redundant whitespace

Reformat: remove redundant whitespace

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/Reefersleep/sleepydo.git/'


Add styling so that textarea has no outline...

... when active.


First cut of TAP reporter plugin

First cut of TAP reporter plugin

The basic functionality is there. Some tests on Midje fail and future
facts are not supported, yet.

* src/midje/emission/plugins/tap.clj:

error: pathspec 'src/midje/emission/plugins/tap.clj' did not match any file(s) known to git

--- src/midje/emission/plugins/tap.clj
+++ src/midje/emission/plugins/tap.clj
@@ -0,0 +1,78 @@
+(ns ^{:doc "TAP output. See http://testanything.org"}
+    midje.emission.plugins.tap
+  (:use midje.emission.util)
+  (:require [midje.data.fact :as fact]
+            [midje.emission.state :as state]
+            [midje.emission.plugins.util :as util]
+            [midje.emission.plugins.silence :as silence]
+            [midje.emission.plugins.default-failure-lines :as lines]
+            [clojure.string :as str]))
+
+(def fact-counter (atom 0))
+
+(defn- format-failure-summary [failure-map]
+  (let [[_ _ & more] (lines/summarize failure-map)]
+    (map #(str "# " %) (conj more (apply str (:position failure-map))))))
+
+(defn fail [failure-map]
+  (do
+    (swap! fact-counter inc)
+    (util/emit-lines (format-failure-summary failure-map))
+    (util/emit-one-line
+     (str "not ok " @fact-counter))))
+
+(defn pass []
+  (do
+    (swap! fact-counter inc)
+    (util/emit-one-line (str "ok " @fact-counter))))
+
+(def last-namespace-shown (atom nil))
+
+(defn set-last-namespace-shown! [string]
+  (reset! last-namespace-shown string))
+
+(defn possible-new-namespace [namespace-symbol]
+  (when (not= namespace-symbol @last-namespace-shown)
+    (util/emit-one-line (str "# Namespace " namespace-symbol))
+    (set-last-namespace-shown! namespace-symbol)))
+
+(defn starting-fact-stream []
+  (set-last-namespace-shown! nil))
+
+(defn starting-to-check-fact [fact]
+  (util/emit-one-line (str "# Checking "
+                           (or (fact/name fact)
+                               (fact/description fact)
+                               (str "fact at " (midje-position-string
+                                                [(fact/file fact)
+                                                 (fact/line fact)]))))))
+
+
+(defn finishing-fact-stream [midje-counters clojure-test-map]
+  (let [passes-and-failures (+ (:midje-passes midje-counters) (:midje-failures midje-counters))]
+    (util/emit-one-line (str 1 ".." passes-and-failures
+                             (when-not passes-and-failures
+                               "# No facts were checked. Is that what you wanted?")))))
+
+(defn future-fact [description-list position]
+  (util/emit-one-line "")
+  (util/emit-one-line (str "WORK TO DO" " "
+                           (when-let [doc (util/format-nested-descriptions description-list)]
+                             (str (pr-str doc) " "))
+                           "at " (util/filename-lineno position))))
+
+(defn make-map [& keys]
+  (zipmap keys
+          (map #(ns-resolve *ns* (symbol (name %))) keys)))
+
+
+(def emission-map (merge silence/emission-map
+                         (make-map :fail
+                                   :pass
+                                   :future-fact
+                                   :starting-to-check-fact
+                                   :possible-new-namespace
+                                   :finishing-fact-stream
+                                   :starting-fact-stream)))
+
+(state/install-emission-map emission-map)


simplewebrtc

simplewebrtc

--- src/cljs/rtcviewr/core.cljs
+++ src/cljs/rtcviewr/core.cljs
@@ -17,10 +17,11 @@

 (toolbarManager (qs ".header") (qs ".controls"))

-(def webrtc (js/SimpleWebRTC. (js-obj
-  :localVideoEl "mini-video"
-  :remoteVideosEl "remotesVideos"
-  :autoRequestMedia true))))
+(def webrtc (js/SimpleWebRTC.
+  #js {
+      :localVideoEl "mini-video"
+      :remoteVideosEl "remotesVideos"
+      :autoRequestMedia true}))

 (.on webrtc "readyToCall" (fn[]
   (.joinRoom webrtc "myroom1")))


add max-threads config also for heroku

add max-threads config also for heroku

--- src/ruuvi_server/heroku/config.clj
+++ src/ruuvi_server/heroku/config.clj
@@ -23,6 +23,7 @@
        }))

   (def server-port (Integer/parseInt (System/getenv "PORT")))
+  (def max-threads 20)
   (defdb db (postgres database-config))
   (init-entities)
 )


Checking base conversion tests

Checking base conversion tests

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/xcthulhu/clj-bitauth.git/'


Code to automatically generate Java interface to conexp-clj

Signed-off-by: Daniel Borchmann <25857343a15bf1edafebc2912e82ecf775c585c1@mailbox.tu-dresden.de>

error: pathspec 'src/conexp/contrib/java.clj' did not match any file(s) known to git

--- src/conexp/contrib/java.clj
+++ src/conexp/contrib/java.clj
@@ -0,0 +1,114 @@
+;; Copyright (c) Daniel Borchmann. All rights reserved.
+;; The use and distribution terms for this software are covered by the
+;; Eclipse Public License 1.0 (http://opensource.org/licenses/eclipse-1.0.php)
+;; which can be found in the file LICENSE at the root of this distribution.
+;; By using this software in any fashion, you are agreeing to be bound by
+;; the terms of this license.
+;; You must not remove this notice, or any other, from this software.
+
+(ns conexp.contrib.java
+  (:use conexp.base)
+  (:use clojure.java.io)
+  (:require conexp.main
+            clojure.pprint))
+
+;;;
+
+(defn- to-valid-Java-name
+  "Convert old-name to a valid Java variable name."
+  [old-name]
+  (let [new-name (-> (str old-name)
+                     (.replaceAll "-" "_")
+                     (.replaceAll " " "_")
+                     (.replaceAll "!" "")
+                     (.replaceAll "<" "_lt_")
+                     (.replaceAll ">" "_gt_")
+                     (.replaceAll "=" "_eq_"))]
+    (symbol
+     (if (.endsWith new-name "?")
+       (if-not (.startsWith new-name "has")
+         (str "is_" (subs new-name 0 (dec (count new-name))))
+         (subs new-name 0 (dec (count new-name))))
+       new-name))))
+
+(defvar- conexp-functions
+  (let [public-map (ns-publics 'conexp.main)]
+    (reduce! (fn [map [sym, ^clojure.lang.Var var]]
+               (if-not (.isMacro var)
+                 (conj! map [(to-valid-Java-name sym) var])
+                 map))
+             {}
+             public-map))
+  "All functions exported by conexp-clj, as a set of Vars.")
+
+(defn- dissect-arglist
+  [arglist]
+  (let [[a b] (split-with #(not= '& %) arglist)]
+    [a (rest b)]))
+
+(defn- function-signatures
+  "Returns sequence of function signatures, each being suitable for
+  gen-class."
+  [new-name, ^clojure.lang.Var var]
+  (let [arglists (:arglists (meta var)),
+        return   (or (:tag (meta var)) 'Object)]
+    (if-not arglists
+      nil
+      (for [arglist arglists]
+        (let [arglist-split (dissect-arglist arglist)]
+          [new-name
+           (if (empty? (second arglist-split))
+             (vec (map (constantly 'Object)
+                       (first arglist-split)))
+             (conj (vec (map (constantly 'Object)
+                             (first arglist-split)))
+                   'objects))
+           return])))))
+
+(defn- generate-definition
+  "Generates function definition with name new-name, calling orig-name
+  with supplied arguments. Prepends prefix before new-name"
+  [prefix new-name orig-name & arglists]
+  `(defn ~(symbol (str prefix new-name))
+     ~@(for [args arglists]
+         (let [arglist-split (dissect-arglist args)]
+           `(~args
+             ~(if (not-empty (second arglist-split))
+                `(apply ~(symbol orig-name) ~@(first arglist-split) ~@(second arglist-split))
+                `(~(symbol orig-name) ~@(first arglist-split))))))))
+
+;;;
+
+(defn generate-java-interface
+  "Given a name of a file generates the code for the Java interface in
+  that file. After this has been compiled it can be used to call
+  conexp-clj functions from Java."
+  [file-name]
+  (with-open [out (writer file-name)]
+    (binding [*out* out]
+      (clojure.pprint/pprint
+       `(do
+          (ns ~'conexp.contrib.JavaInterface
+            (:require conexp.main)
+            (:gen-class
+             :prefix ~'conexp-clj-
+             :methods ~(map #(with-meta % {:static true})
+                            (mapcat #(apply function-signatures %)
+                                    conexp-functions))))
+
+          (import 'conexp.fca.contexts.Context)
+          (import 'conexp.fca.lattices.Lattice)
+          (import 'conexp.fca.association_rules.Association-Rule)
+
+          ~@(for [[new-name, ^clojure.lang.Var var] conexp-functions]
+              (let [orig-name (symbol (str (.ns var)) (str (.sym var))),
+                    arglists  (:arglists (meta var))]
+                (apply generate-definition
+                       "conexp-clj-"
+                       new-name
+                       orig-name
+                       arglists))))))))
+
+;;;
+
+nil


Implement add-component-symbol

Implement add-component-symbol

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/kkroening/jackal.git/'


Update compiler.clj

Update compiler.clj

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/parenode/clojure-cup-2015.git/'


Demo namespace

Demo namespace

error: pathspec 'src/test/clojure/dojo/demo.clj' did not match any file(s) known to git

--- src/test/clojure/dojo/demo.clj
+++ src/test/clojure/dojo/demo.clj
@@ -0,0 +1,36 @@
+(ns dojo.demo
+  (:use [clojure.core.matrix])
+  (:use [clojure.repl])
+  (:require [clojure.data.csv :as csv])
+  (:require [clojure.java.io :as io])
+  (:require [clojure.core.matrix.dataset :as ds])
+  (:require [incanter.core :as ic]
+            [incanter.charts :as ich]
+            [incanter.stats :as is]))
+
+;; Dataset loading
+
+(comment
+  (def data
+    (with-open [in-file (io/reader (io/resource "EPL-2012-13.csv"))]
+      (let [lines (doall (csv/read-csv in-file))
+            names (first lines)
+            rows (next lines)]
+        (ds/dataset names rows))))
+
+  (shape data)
+
+  (ds/column-names data)
+
+  (distinct (ds/column data "HomeTeam"))
+)
+
+;; Incanter stuff
+
+(comment
+  ;; histogram
+  (ic/view (ich/histogram (is/sample-normal 1000)))
+
+  ;; function plot
+  (ic/view (ich/function-plot logistic -10 10))
+)


don't pass nil customers off to query

don't pass nil customers off to query

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/starcity-properties/odin.git/'


Update project dependencies.

Update project dependencies.

--- project.clj
+++ project.clj
@@ -6,12 +6,13 @@
   :scm {:name "git" :url "http://github.com/finagle/finagle-clojure"}
   :dependencies [[finagle-clojure/core "0.1.2-SNAPSHOT"]
                  [finagle-clojure/thrift "0.1.2-SNAPSHOT"]
-                 [finagle-clojure/thriftmux "0.1.2-SNAPSHOT"]]
+                 [finagle-clojure/thriftmux "0.1.2-SNAPSHOT"]
+                 [finagle-clojure/http "0.1.2-SNAPSHOT"]]
   :plugins [[lein-sub "0.3.0"]
             [codox "0.8.10"]
             [lein-midje "3.1.3"]]
-  :sub ["core" "thrift"]
-  :codox {:sources ["core/src" "thrift/src" "thriftmux/src"]
+  :sub ["core" "thrift" "http"]
+  :codox {:sources ["core/src" "thrift/src" "thriftmux/src" "http/src"]
           :defaults {:doc/format :markdown}
           :output-dir "doc/codox"
           :src-dir-uri "https://github.com/finagle/finagle-clojure/blob/master/"


Add doo to dev dependencies

Add doo to dev dependencies

--- project.clj
+++ project.clj
@@ -38,13 +38,13 @@
                  :pretty-print true
                  :externs ["externs/hickory.js"]
                  :verbose true}
-                :notify-command ["bin/phantomjs" "advanced"]
                 :source-paths ["src" "test"]}]
               :test-commands {"phantom" ["bin/phantomjs"]}}
   :deploy-repositories [["releases" :clojars]]
   :profiles {:dev {:dependencies [[cljsjs/jquery "2.1.4-0"]
                                   [crate "0.2.5"]
                                   [criterium "0.4.3"]
+                                  [doo "0.1.6"]
                                   [hickory "0.5.4"]
                                   [reagent "0.5.1"]]
                    :plugins [[lein-cljsbuild "1.1.1"]


Updating restQL-core dep

Updating restQL-core dep

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/B2W-BIT/restQL-server.git/'


Deps updates

Deps updates

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/physion/ovation-webapi.git/'


Update deps

Update deps

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/democracyworks/electorate-works.git/'


lein-release plugin: bumped version from 0.2.14 to 0.2.15-SNAPSHOT for next development cycle

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject sablono "0.2.14"
+(defproject sablono "0.2.15-SNAPSHOT"
   :description "Lisp style templating for Facebook's React."
   :url "http://github.com/r0man/sablono"
   :author "Roman Scherer"


Version 0.5.2

Version 0.5.2

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject sablono "0.5.2-SNAPSHOT"
+(defproject sablono "0.5.2"
   :description "Lisp style templating for Facebook's React."
   :url "http://github.com/r0man/sablono"
   :author "r0man"


Update manifold to the latest stable release.

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/tcsavage/cats.git/'


Version 1.9.3-SNAPSHOT

Version 1.9.3-SNAPSHOT


Version 1.8.1-SNAPSHOT

Version 1.8.1-SNAPSHOT


Update ClojureScript

Update ClojureScript

--- project.clj
+++ project.clj
@@ -7,7 +7,7 @@
             :url "http://www.eclipse.org/legal/epl-v10.html"}
   :dependencies [[com.facebook/react "0.9.0.2"]
                  [org.clojure/clojure "1.6.0"]
-                 [org.clojure/clojurescript "0.0-2268" :scope "provided"]]
+                 [org.clojure/clojurescript "0.0-2277" :scope "provided"]]
   :deploy-repositories [["releases" :clojars]]
   :cljsbuild {:builds []}
   :profiles {:dev {:dependencies [[reagent "0.4.2"]


Bump log4j/sl4j reqs

Bump log4j/sl4j reqs

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/terrancesnyder/engulf.git/'


problem_0144.clj

error: pathspec 'src/project_euler/problem_0144.clj' did not match any file(s) known to git

--- src/project_euler/problem_0144.clj
+++ src/project_euler/problem_0144.clj
@@ -0,0 +1,81 @@
+(ns project-euler.problem-0144)
+
+;; In laser physics, a "white cell" is a mirror system that acts as a delay line for the laser beam.
+;; The beam enters the cell, bounces around on the mirrors, and eventually works its way back out.
+
+;; The specific white cell we will be considering is an ellipse with the equation 4x^2 + y^2 = 100
+
+;; The section corresponding to −0.01 ≤ x ≤ +0.01 at the top is missing,
+;; allowing the light to enter and exit through the hole.
+
+;; The light beam in this problem starts at the point (0.0,10.1) just outside the white cell,
+;; and the beam first impacts the mirror at (1.4,-9.6).
+
+;; Each time the laser beam hits the surface of the ellipse,
+;; it follows the usual law of reflection "angle of incidence equals angle of reflection."
+;; That is, both the incident and reflected beams make the same angle with the normal line at the point of incidence.
+
+;; In the figure on the left,
+;; the red line shows the first two points of contact between the laser beam and the wall of the white cell;
+;; the blue line shows the line tangent to the ellipse at the point of incidence of the first bounce.
+
+;; The slope m of the tangent line at any point (x,y) of the given ellipse is: m = −4x/y
+
+;; The normal line is perpendicular to this tangent line at the point of incidence.
+
+;; The animation on the right shows the first 10 reflections of the beam.
+
+;; How many times does the beam hit the internal surface of the white cell before exiting?
+
+;;========================================================================================================
+
+(defn scalar-mult [[x y] s] [(* x s) (* y s)])
+(defn dot-product [[x0 y0] [x1 y1]] (+ (* x0 x1) (* y0 y1)))
+(defn sub-vect    [[x0 y0] [x1 y1]] [(- x0 x1) (- y0 y1)])
+(defn reflection [vec-i vec-n]
+  (sub-vect (scalar-mult vec-n
+                         (* 2 (dot-product vec-n vec-i)))
+            vec-i))
+
+(defn distance2 [[x1 y1] [x2 y2]]
+  (let [dx (- x1 x2)
+        dy (- y1 y2)]
+    (+ (* dx dx) (* dy dy))))
+
+(defn intersection [[x0 y0] [n-x n-y]]
+  (let [k (/ n-y n-x)
+        j (- y0 (* k x0))
+        a (+ 4 (* k k))
+        b (* 2 k j)
+        c (- (* j j) 100)
+        sqrt-d (Math/sqrt (- (* b b) (* 4 a c)))
+        x1 (/ (+ b sqrt-d) -2 a)
+        x2 (/ (- sqrt-d b) 2 a)]
+    (->> [[x1 (+ (* k x1) j)]
+          [x2 (+ (* k x2) j)]]
+         (apply max-key (fn [p] (distance2 p [x0 y0]))))))
+
+(defn next-hit [[x0 y0] [x1 y1]]
+  (let [tan-n (/ y1 x1 -4)
+        sec-n (Math/sqrt (+ 1 (* tan-n tan-n)))
+        sin-n (/ tan-n sec-n)
+        cos-n (/ sec-n)
+        vec-n (if (< x1 0) [cos-n (- sin-n)] [(- cos-n) sin-n])
+        dx (- x0 x1)
+        dy (- y0 y1)
+        hyp (Math/sqrt (+ (* dx dx) (* dy dy)))
+        vec-i [(/ dx hyp) (/ dy hyp)]
+        vec-s (reflection vec-i vec-n)]
+    #_(println vec-n vec-i vec-s)
+    (intersection [x1 y1] vec-s)))
+
+(defn solution []
+  (->> (iterate
+        (fn [[p0 p1]]
+          [p1 (next-hit p0 p1)])
+        [[0.0 10.1] [1.4 -9.6]])
+       (take-while (fn [[_ [x y]]] (not (and (> y 9)
+                                             (<= -0.01 x 0.01)))))
+       count))
+
+;; 354


println kendu

println kendu

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/lnmnd/magnet.bez.git/'


api-erantzuna ez errepikatu

api-erantzuna ez errepikatu

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/lnmnd/magnet.zer.git/'


Add deps.cljs for Shadow-CLJS and Cljs :install-deps

error: pathspec 'src/deps.cljs' did not match any file(s) known to git


Fix to prefix

Fix to prefix

--- dev/src/yada/dev/user_manual.clj
+++ dev/src/yada/dev/user_manual.clj
@@ -151,7 +151,7 @@
       (str/replace #"\{\{(.+)\}\}" #(System/getProperty (last %)))
       (str/replace #"
\s*
" "")
       (str/replace #"(yada)(?![-/])" "yada")
-      (str/replace "localhost:8090" (:prefix replacements))
+      (str/replace "http://localhost:8090" (:prefix replacements))
       ))

 (defn body [{:keys [*router templater] :as user-manual} doc replacements]


Seven Languages in Seven Weeks: Clojure day 1.

error: pathspec 'SevenLanguages/Clojure/day1.clj' did not match any file(s) known to git

--- SevenLanguages/Clojure/day1.clj
+++ SevenLanguages/Clojure/day1.clj
@@ -0,0 +1,9 @@
+(defn big [st n]
+    (> (count st) n))
+
+(defn collection-type [col]
+    (cond
+        (list? col) :list
+        (map? col) :map
+        (vector? col) :vector))
+


cookies

cookies

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/edgar615/ring-study.git/'


Rebinding vars different way

Rebinding vars different way

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/michaelsbradleyjr/shen.clj.git/'


Simplistic version of the system primitive that might get introduces


ensure notes are shown in expanded row

ensure notes are shown in expanded row


Fix generated arglists

Fix generated arglists

This is a fix for issue #831 (https://github.com/Netflix/Hystrix/issues/831) which
is a blocker for http://dev.clojure.org/jira/browse/CLJ-1232. Instead of generating
:arglists as (list (quote [..])*), generate (quote ([..]*)). Tests still
pass and (doc command) works as intended. I have not directly tested
this with Clojure patched with CLJ-1232.

--- hystrix-contrib/hystrix-clj/src/main/clojure/com/netflix/hystrix/core.clj
+++ hystrix-contrib/hystrix-clj/src/main/clojure/com/netflix/hystrix/core.clj
@@ -410,7 +410,7 @@
         group-key           (str *ns*)
         [m [params & body]] (split-def-meta opts)
         m                   (if-not (contains? m :arglists)
-                              (assoc m :arglists `(list (quote ~params)))
+                              (assoc m :arglists (list 'quote `(~params)))
                               m)]
     `(let [meta-options# (#'com.netflix.hystrix.core/extract-hystrix-command-options ~m)
            run-fn#       (fn ~name ~params ~@body)


comments

comments

--- src/cavm/h2.clj
+++ src/cavm/h2.clj
@@ -751,6 +751,11 @@
 ; so we can't pass in the matrix seq w/o blowing the heap. We
 ; pass in a function to return the seq, instead.

+; files: the files this matrix was loaded from, e.g. clinical & genomic matrix, plus their timestamps & file hashes
+; metadata: the metadata for the matrix (should cgdata mix in the clinical metadata?)
+; matrix-fn: function to return seq of data rows
+; features: field metadata. Need a better name for this.
+
 (defn load-exp
   "Load matrix file and metadata. Skips the data load if file hashes are unchanged,
   and 'force' is false. Metadata is always updated."
@@ -817,7 +822,7 @@
                  (not (= (set files) (set (related-sources probemaps pmid)))))
          (load-related-sources
            probemap_sources :probemaps_id pmid files)
-         (dorun (map add-probe probes)))))))
+         (dorun (map add-probe probes))))))) ; XXX change to doseq?

 (defn create-db [file & [{:keys [classname subprotocol delimiters make-pool?]
                           :or {classname "org.h2.Driver"


Initial commit of rule to generate the CHEBI:protein - PR:protein identifier exact match linkage

error: pathspec 'resources/rules/pre_identifier_merge/step_b_id_exact_match/shared_label/protein_class_consolidation_by_shared_label.clj' did not match any file(s) known to git

--- resources/rules/pre_identifier_merge/step_b_id_exact_match/shared_label/protein_class_consolidation_by_shared_label.clj
+++ resources/rules/pre_identifier_merge/step_b_id_exact_match/shared_label/protein_class_consolidation_by_shared_label.clj
@@ -0,0 +1,24 @@
+;; ------------------------------------------------------------
+;; ---------  relation consolidation via shared label ---------
+;; ------------------------------------------------------------
+`{:name          "protein-class-consolidation-by-shared_label"
+  :title         "creates exactMatch mappings between Class identifiers whose classes have the label 'protein'. Generally we have excluded collapsing any PR concepts based on shared label for fear of accidentally collapsing genes with proteins. In the case of 'protein' however, we do want to collapse CHEBI:protein with PR:protein."
+  :head          ((?/id1 skos/exactMatch ?/id2))
+  :sparql-string "prefix franzOption_clauseReorderer: <franz:identity>
+                 prefix franzOption_chunkProcessingAllowed: <franz:yes>
+  prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
+    prefix oboInOwl: <http://www.geneontology.org/formats/oboInOwl#>
+select ?c1 ?c2 ?label {
+                       ?c1 oboInOwl:hasOBONamespace ?ns1 .
+                       ?c1 rdf:type owl:Class .
+                       ?c1 rdfs:label ?label .
+                       ?c2 rdfs:label ?label .
+                       ?c2 oboInOwl:hasOBONamespace ?ns2 .
+                       ?c2 rdf:type owl:Class .
+                       # the one PR collapse that we know is safe is CHEBI:protein = PR:protein
+                       FILTER (?c1 != ?c2 && STR(IRI(?c1)) < STR(IRI(?c2))
+                                   && ?label = 'protein')
+                       ?id1 obo:IAO_0000219 ?c1 .
+                       ?id2 obo:IAO_0000219 ?c2 .
+                       }"
+  }


invatam sa actionam

invatam sa actionam

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/kokosro/kokos-crawler.git/'


Forgot to register all.clj with github!

Forgot to register all.clj with github!

error: pathspec 'src/aerobio/validate/all.clj' did not match any file(s) known to git

--- src/aerobio/validate/all.clj
+++ src/aerobio/validate/all.clj
@@ -0,0 +1,117 @@
+(ns aerobio.validate.all
+  (:require
+   [clojure.pprint :refer [pprint]]
+   [clojure.spec.alpha :as s]
+   [phrase.alpha :as p
+    :refer [defphraser phrase phrase-first]]
+
+   [clojure.string :as cljstr]
+   [aerial.utils.string :as str]
+   [aerial.fs :as fs]
+
+   [aerobio.params :as pams]
+   [aerobio.validate
+    [common :as vc
+     :refer [make-sheet-fspec eolOK?
+             set-exp-sheet-data validate-msg make-validator]]
+    [sampsheet :refer [validate-sample-sheet]]
+    [expsheet :refer [validate-exp-sample-sheet]]
+    [compsheet :refer [validate-comparison-sheet]]]
+
+   [aerobio.htseq.common :as ac]))
+
+
+(defn check-for-sampsheet [EID]
+  (fs/file? (make-sheet-fspec EID "SampleSheet.csv")))
+
+(defn check-for-expsheet [EID]
+  (fs/file? (make-sheet-fspec EID "Exp-SampleSheet.csv")))
+
+(defn check-for-compsheet [EID]
+  (fs/file? (make-sheet-fspec EID "ComparisonSheet.csv")))
+
+(s/def ::sampsheet check-for-sampsheet)
+(s/def ::expsheet  check-for-expsheet)
+(s/def ::compsheet check-for-compsheet)
+
+(s/def ::sheets?
+  (s/keys :req-un [::sampsheet ::expsheet ::compsheet]))
+
+
+(p/defphraser check-for-sampsheet
+  [_ problem]
+  "is missing required 'SampleSheet.csv'")
+
+(p/defphraser check-for-expsheet
+  [_ problem]
+  "is missing required 'Exp-SampleSheet.csv'")
+
+(p/defphraser check-for-compsheet
+  [_ problem]
+  "is missing required 'ComparisonSheet.csv'")
+
+(def validate-files-exist (make-validator ::sheets? :sep "\n"))
+
+(defn validate-sheets-exist [EID]
+  (let [vstg (->> (mapv #(vector % EID) [:sampsheet :expsheet :compsheet])
+                  (into {})
+                  validate-files-exist
+                  (str/split #"\n")
+                  (filter #(not (empty? %)))
+                  (map #(format " %s. %s" %1 %2) (iterate inc 1))
+                  (cljstr/join "\n"))]
+    (with-out-str
+      (when (not (empty? vstg))
+        (print (format "Experiment '%s' - \n" EID)))
+      (print vstg))))
+
+
+
+
+(defn validate-exp [EID action]
+  (set-exp-sheet-data EID)
+  (let [vse (validate-sheets-exist EID)]
+    (with-out-str
+      (if (not (empty? vse))
+        (print vse)
+        (print (cljstr/join
+                "\n\n"
+                (case action
+                  "phase-0"
+                  (filter #(not (empty? %))
+                          [(validate-sample-sheet EID)
+                           (validate-exp-sample-sheet EID)])
+                  "phase-1"
+                  (filter #(not (empty? %))
+                          [(validate-sample-sheet EID)
+                           (validate-exp-sample-sheet EID)
+                           #_(validate-data-sets-phase-1 EID)])
+                  ("all" "phase-2" "compare" "xcompare")
+                  (filter #(not (empty? %))
+                          [(validate-sample-sheet EID)
+                           (validate-exp-sample-sheet EID)
+                           (validate-comparison-sheet EID)]) )))))))
+
+
+(comment
+
+  (aerobio.htseq.common/set-exp "181013_NS500751_0092_AH57C5BGX9")
+  (aerobio.htseq.common/set-exp "190218_NS500751_0120_AHNK5TBGX9")
+  (aerobio.htseq.common/set-exp "190109_NS500751_0113_AHFCW3AFXY")
+  (aerobio.htseq.common/set-exp "190321_NS500751_0124_AH7JMYBGXB")
+  (aerobio.htseq.common/set-exp "150708_Nutr_dropout")
+
+  (def EID "181013_NS500751_0092_AH57C5BGX9")
+  (print (validate-exp EID))
+  (def EID "190218_NS500751_0120_AHNK5TBGX9")
+  (print (validate-exp EID))
+  (def EID "190321_NS500751_0124_AH7JMYBGXB")
+  (print (validate-exp EID))
+
+  (def EID "150708_Nutr_dropout")
+  (print (validate-exp EID))
+
+  (def EID "190109_NS500751_0113_AHFCW3AFXY")
+  (print (validate-exp EID))
+
+  )


Idazterakoan egileak gehitzen joan

Idazterakoan egileak gehitzen joan


Prevent NullPointerException in retry logic

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/democracyworks/email-works.git/'


Cleaning up functions and adding some basic reporting capability

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/couragelabs/coachbot.git/'


(sorry forgot to add multimethods.clj :)

error: pathspec 'src/conexp/util/multimethods.clj' did not match any file(s) known to git

--- src/conexp/util/multimethods.clj
+++ src/conexp/util/multimethods.clj
@@ -0,0 +1,134 @@
+;; Copyright (c) Daniel Borchmann. All rights reserved.
+;; The use and distribution terms for this software are covered by the
+;; Eclipse Public License 1.0 (http://opensource.org/licenses/eclipse-1.0.php)
+;; which can be found in the file LICENSE at the root of this distribution.
+;; By using this software in any fashion, you are agreeing to be bound by
+;; the terms of this license.
+;; You must not remove this notice, or any other, from this software.
+
+(ns conexp.util.multimethods
+  (:use [clojure.contrib.string :only (join)]
+    conexp.util))
+
+;;; multimethod helpers
+
+(defn test-list-types-object
+  "Tests whether the second argument is of a child type of the elements of the
+  first argument, returns the first matching parent type. Returns nil if
+  the second argument is of none of the types in the list.
+
+  Parameters:
+    typelist   _list of types
+    object     _object to test for 'isa?' relation"
+  [typelist object]
+  (let [ is-child-type? (fn [x] (isa? (type object) x))
+         good-types (filter is-child-type? typelist) ]
+    (first good-types)))
+
+(defn insert-before-first-pred
+  "Takes a predicate, a seq and an element and returns a seq
+  that will have the element inserted right before the first
+  element that fulfills the predicate.
+
+  Parameters:
+         pred   _predicate function
+         coll   _sequence
+         item   _new item"
+  [pred coll item]
+  (loop [ construct identity
+          coll coll]
+    (if (empty? coll) (construct (seq (list item)))
+      (let [ head (first coll)
+             tail (rest coll) ]
+        (if (pred head) (construct (cons item coll))
+          (recur (fn [x] (construct (cons head x))) tail))))))
+
+(defmacro get-value-if-defined
+  "Takes a quoted symbol name and returns its value if defined
+   in the current namespace, or nil else"
+  [symbol]
+  `(let [ v# (ns-resolve *ns* ~symbol) ]
+     (when v# (var-get v#))))
+
+(defmacro def-
+  "Private version of def"
+  [name & exprs]
+  `(do
+     (def ~name ~@exprs)
+     (alter-meta! (var ~name) conj {:private true})))
+
+(defmacro in-other-ns
+  "Takes a namespace name and an expression that will be run
+  within the other namespace in an implicit do, then returns
+  to the current namesapce"
+  [ns & exprs]
+  (let [ current-ns (ns-name *ns*) ]
+    `(do
+       (in-ns ~ns)
+       ~@exprs
+       (in-ns (quote ~current-ns)))))
+
+(defmacro inherit-multimethod
+  "Creates a new multimethod that dispatches by type hierarchy
+   on the first parameter and sets the dispatcher to recognize
+   all inherited types, then appends the given documentation.
+   Uses the value of *poly-ns* as namespace for the defmulti
+   definitions, if defined, or the current namespace else."
+  [name type-name doc-str]
+  (let [ poly-ns (get-value-if-defined '*poly-ns*) ]
+    (if poly-ns
+      `(do
+         (in-other-ns (quote ~poly-ns)
+           (inherit-multimethod-local ~name ~type-name ~doc-str))
+         (clojure.core/refer (quote ~poly-ns) :only [(quote ~name)]
+           :rename {(quote ~name) (quote temporary#)})
+         (ns-unmap *ns* (quote ~name))
+         (def ~name temporary#)
+         (alter-meta! (var ~name) conj {:doc
+           (str "Please refer to:\n\t(doc " (quote ~poly-ns)
+             "/" (quote ~name) ")")})
+         (ns-unmap *ns* (quote temporary#)))
+      `(inherit-multimethod-local ~name ~type-name ~doc-str))))
+
+
+(defmacro inherit-multimethod-local
+  "Creates a new multimethod that dispatches by type hierarchy
+   on the first parameter and sets the dispatcher to recognize
+   all inherited types, then appends the given documentation."
+  [name type-name doc-str]
+  (let [name-str (str name)]
+    `(let [ old-meta# (meta ((ns-map *ns*) (quote ~name)))
+            old-doc-strings-val# (if (nil? old-meta#) {} (:doc-strings old-meta#))
+            old-doc-strings# (if (nil? old-doc-strings-val#) {} old-doc-strings-val#)
+            old-types# (if (nil? old-meta#) (list) (:type-list old-meta#))]
+       (defonce ~name nil)
+       (let [ old-func# ~name
+              doc-strings# (conj old-doc-strings#
+                             {~type-name (str ~type-name "\n=====\n" ~doc-str)})
+              is-new-type# (not (some #{~type-name} old-types#))
+              types#  (if is-new-type#
+                        (insert-before-first-pred (fn [x#] (isa? ~type-name x#))
+                          old-types# ~type-name)
+                        old-types#)
+              new-doc# (join "\n+++++\n\n"
+                         (cons (str "is a multimethod dispatched"
+                                 " on type of the first argument...")
+                           (map doc-strings# types#)))]
+         (when is-new-type#
+           (defmulti ~name (fn [x# & args#] (test-list-types-object types# x#)))
+           (defmethod ~name nil [& args#]
+             (illegal-argument (str ~name-str
+                                 " called, but there is no method declared for type "
+                                 (when-not (empty? args#) (type (first args#))) "!"  )))
+           (defmethod ~name ~type-name [& args#]
+             (illegal-argument (str ~name-str
+                                 " called, but there is a method declared but"
+                                 " not defined for type "
+                                 (when-not (empty? args#) (type (first args#))) "!"  )))
+           (doseq [t# old-types#]
+             (defmethod ~name t# [& args#] (apply old-func# args#))))
+         (.setMeta (var ~name) (conj (meta (var ~name))
+                                 {:doc new-doc#
+                                 :doc-strings doc-strings#
+                                 :type-list types#}))))))
+


Refactoring.

Refactoring.

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/couragelabs/crispy-tatertot.git/'


Remove "Data View" from pipeline UI

Remove "Data View" from pipeline UI

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/t6/itac-summary.git/'


Fix grammar problem, closes #23

Fix grammar problem, closes #23

Thanks to @jamieorc for reporting.

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/croeder/clojure-koans-work.git/'


add p17.clj

add p17.clj

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/drcabana/euler-fp.git/'


added go! function for easier startup

added go! function for easier startup

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/starcity-properties/odin.git/'


Egilea behar ez

Egilea behar ez

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/lnmnd/magnet.bez.git/'


Added completion generation script (thanks to Parth Malwankar)

error: pathspec 'bin/gen-completions.clj' did not match any file(s) known to git

--- bin/gen-completions.clj
+++ bin/gen-completions.clj
@@ -0,0 +1,21 @@
+; Copyright (c) 2006 Parth Malwankar
+; All rights reserved.
+;
+; A small script to generate a dictionary of Clojure's core
+; functions. The script was written by Parth Malwankar. It
+; is included in VimClojure with his permission.
+;  -- Meikel Brandmeyer, 16 August 2008
+;     Frankfurt am Main, Germany
+;
+; See also: http://en.wikibooks.org/wiki/Clojure_Programming
+;
+(defmacro with-out-file [pathname & body]
+  `(with-open stream# (new java.io.FileWriter ~pathname)
+     (binding [*out* stream#]
+       ~@body)))
+
+(def completions (keys (ns-publics (find-ns 'clojure))))
+
+(with-out-file "clj-keys.txt"
+  (doseq x completions
+    (println x)))


PUT /api/meta/db/:id

PUT /api/meta/db/:id

--- src/metabase/api/meta/db.clj
+++ src/metabase/api/meta/db.clj
@@ -1,6 +1,6 @@
 (ns metabase.api.meta.db
   "/api/meta/db endpoints."
-  (:require [compojure.core :refer [GET POST DELETE]]
+  (:require [compojure.core :refer [GET POST PUT DELETE]]
             [korma.core :refer :all]
             [medley.core :as medley]
             [metabase.api.common :refer :all]
@@ -33,6 +33,11 @@
 (defendpoint GET "/:id" [id]
   (->404 (sel :one Database :id id)
          (hydrate :organization)))
+
+(defendpoint PUT "/:id" [id :as {{:keys [name engine details]} :body}]
+  (println name engine details)
+  (write-check Database id)
+  (check-500 (upd Database id :name name :engine engine :details details)))

 (defendpoint DELETE "/:id" [id]
   (write-check Database id)


Add sleipnir and cats deps

Add sleipnir and cats deps

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/bsima/aristotl.git/'


Update deps

Update deps


Add serializers namespace.

Add serializers namespace.

error: pathspec 'src/clojure/catacumba/serializers.clj' did not match any file(s) known to git

--- src/clojure/catacumba/serializers.clj
+++ src/clojure/catacumba/serializers.clj
@@ -0,0 +1,91 @@
+;; Copyright (c) 2015 Andrey Antukh <niwi@niwi.nz>
+;; All rights reserved.
+;;
+;; Redistribution and use in source and binary forms, with or without
+;; modification, are permitted provided that the following conditions
+;; are met:
+;;
+;; 1. Redistributions of source code must retain the above copyright
+;;    notice, this list of conditions and the following disclaimer.
+;; 2. Redistributions in binary form must reproduce the above copyright
+;;    notice, this list of conditions and the following disclaimer in the
+;;    documentation and/or other materials provided with the distribution.
+;;
+;; THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+;; IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+;; OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+;; IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+;; INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+;; NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+;; DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+;; THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+;; (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+;; THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+(ns catacumba.serializers
+  "A serializers abstraction layer."
+  (:require [cheshire.core :as json]
+            [cognitect.transit :as transit]
+            [buddy.core.codecs :as codecs])
+  (:import java.io.ByteArrayInputStream
+           java.io.ByteArrayOutputStream))
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;; Public Api
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+
+(defn- str->bytes
+  [data]
+  (.getBytes data "UTF-8"))
+
+(defn bytes->str
+  [data]
+  (String. data "UTF-8"))
+
+(defmulti encode
+  "Encode data."
+  (fn [data type] type))
+
+(defmulti decode
+  "Decode data."
+  (fn [data type] type))
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;; Implementation
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+
+(defmethod encode :json
+  [data _]
+  (-> (json/encode data)
+      (codecs/str->bytes)))
+
+(defmethod decode :json
+  [data _]
+  (-> (codecs/bytes->str data)
+      (json/decode true)))
+
+(defmethod encode :transit+json
+  [data _]
+  (with-open [out (ByteArrayOutputStream.)]
+    (let [w (transit/writer out :json)]
+      (transit/write w data)
+      (.toByteArray out))))
+
+(defmethod encode :transit+msgpack
+  [data _]
+  (with-open [out (ByteArrayOutputStream.)]
+    (let [w (transit/writer out :msgpack)]
+      (transit/write w data)
+      (.toByteArray out))))
+
+(defmethod decode :transit+json
+  [data _]
+  (with-open [input (ByteArrayInputStream. data)]
+    (let [reader (transit/reader input :json)]
+      (transit/read reader))))
+
+(defmethod decode :transit+msgpack
+  [data _]
+  (with-open [input (ByteArrayInputStream. data)]
+    (let [reader (transit/reader input :msgpack)]
+      (transit/read reader))))


Use new arg to set the default val for doc-enabled? atom

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/bsmr-clojure/Nightcode.git/'


[WM] Bump ext. service timeout to 10s

[WM] Bump ext. service timeout to 10s

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/democracyworks/user-http-api.git/'