commit stringlengths 40 40 | old_file stringlengths 4 264 | new_file stringlengths 4 264 | old_contents stringlengths 0 4.24k | new_contents stringlengths 1 5.44k | subject stringlengths 14 778 | message stringlengths 15 9.92k | lang stringclasses 277
values | license stringclasses 13
values | repos stringlengths 5 127k |
|---|---|---|---|---|---|---|---|---|---|
27d10798d0ea627297ebca668dc6f966ec077be7 | src/petulant_life/main.clj | src/petulant_life/main.clj | (ns petulant-life.main
(:import (org.lwjgl.opengl DisplayMode
Display
GL11
ContextAttribs
PixelFormat))
(:require [petulant-life.rendering :as r]))
; Defining some width and height constraints to th... | (ns petulant-life.main
(:import (org.lwjgl.opengl DisplayMode
Display
GL11
ContextAttribs
PixelFormat))
(:require [petulant-life.rendering :as r]))
; Defining some width and height constraints to th... | Make sure we always call destroy! | Make sure we always call destroy!
| Clojure | mit | crockeo/petulant-life |
d9f292065e376cfef4ac4e328fc4db722d498c74 | edge-app-template/resources/clj/new/app.template/main.cljs | edge-app-template/resources/clj/new/app.template/main.cljs | (ns {{root-ns}}.frontend.main)
(js/console.log "Hello, world")
(set! (.-innerText (js/document.getElementById "app")) "Loaded {{name}}!")
| (ns ^:figwheel-hooks {{root-ns}}.frontend.main)
(js/console.log "Hello, world")
;; This is called once
(defonce init
(do (set! (.-innerText (js/document.getElementById "app")) "Loaded {{name}}!") true))
;; This is called every time you make a code change
(defn ^:after-load reload []
(set! (.-innerText (js/docume... | Add hot reloading example to edge app template | Add hot reloading example to edge app template
| Clojure | mit | juxt/edge,juxt/edge |
c4d15901b44f850d28dd1341571064631984dba3 | project/analyze-data/src/analyze_data/predict.clj | project/analyze-data/src/analyze_data/predict.clj | (ns analyze-data.predict
(:require [clojure.core.matrix :as m]
[analyze-data.dataset.create.core :refer [document-to-vector]]
[analyze-data.knn.core :as knn]
[analyze-data.naive-bayes.predict :as naive-bayes]))
(defmulti predict
"Predict a label for z.
model: previously train... | (ns analyze-data.predict
(:require [clojure.core.matrix :as m]
[analyze-data.dataset.create.core :refer [document-to-vector]]
[analyze-data.knn.core :as knn]
[analyze-data.naive-bayes.predict :as naive-bayes]))
(defmulti predict
"Predict a label for z.
model: previously train... | Fix pointer to knn options in docs. | Fix pointer to knn options in docs.
| Clojure | mit | dylanfprice/stanfordml,dylanfprice/stanfordml |
65f1d8dcee9e27c20bb984b6484a1bbd9282e9b9 | src/icecap/store/riak.clj | src/icecap/store/riak.clj | (ns icecap.store.riak
(:require [clojure.core.async :as a :refer [thread]]
[clojurewerkz.welle.kv :as kv]
[icecap.store.api :refer [Store]]))
(defn riak-store
"Creates a Riak-backed store."
[conn bucket]
(reify Store
(create! [_ index blob]
(thread (kv/store conn bucket index ... | (ns icecap.store.riak
(:require [clojure.core.async :as a :refer [thread]]
[clojurewerkz.welle.kv :as kv]
[icecap.store.api :refer [Store]]))
(defn riak-store
"Creates a Riak-backed store."
[conn bucket]
(reify Store
(create! [_ index blob]
(thread (kv/store conn bucket index ... | Fix a bug in bucket-props | Fix a bug in bucket-props
| Clojure | epl-1.0 | Hatnik/icecap,lvh/icecap |
844aa974d028d60a21d7febd416e828b311c4feb | src/useful/string.clj | src/useful/string.clj | (ns useful.string
(:use [clojure.string :only [join split capitalize]]))
(defn camelize [s & [lower]]
(let [parts (split (str s) #"-|_")]
(apply str
(if lower
(cons (first parts) (map capitalize (rest parts)))
(map capitalize parts)))))
(defn dasherize [s]
(.. (re-matche... | (ns useful.string
(:use [clojure.string :only [join split capitalize]]))
(defn camelize [str]
(s/replace str
#"-(\w)"
(comp s/upper-case second))[s & [lower]])
(defn dasherize [name]
(s/replace name
#"(?<![A-Z])[A-Z]+"
(comp (partial str "-")
... | Copy my improved versions of dasherize and camelize from cake | Copy my improved versions of dasherize and camelize from cake
| Clojure | epl-1.0 | amalloy/useful,flatland/useful,jafingerhut/useful |
2a37c885915f802c58c81fa93378c84b93275bed | src/little_clojurer/chapter3.clj | src/little_clojurer/chapter3.clj | (ns little-clojurer.chapter3
(:require [little-clojurer.chapter1 :refer :all])
(:require [little-clojurer.chapter2 :refer :all]))
(defn rember
"Return lst with the first instance of item removed."
[item lst]
nil)
| (ns little-clojurer.chapter3
(:require [little-clojurer.chapter1 :refer :all])
(:require [little-clojurer.chapter2 :refer :all]))
(defn rember
"Return lst with the first instance of item removed."
[item lst]
nil)
(defn firsts
"Takes a list of lists, return a list made out of first item of each sublist."
... | Add all function stubs for chapter 3. | Add all function stubs for chapter 3.
| Clojure | mit | optimizely/little-clojurer-public |
e4d2f920967312c0c53858b386a3146112d9d338 | scripts/ci/lumo_script.clj | scripts/ci/lumo_script.clj | (require '[cljs.nodejs :as nodejs])
(require '[clojure.test :as test])
(require '[mikron.test]))
(nodejs/enable-util-print!)
(defmethod test/report [::test/default :summary] [{:keys [fail error] :as summary}]
(println "Test summary: " summary)
(.exit nodejs/process (if (= 0 fail error) 0 1)))
| (require '[cljs.nodejs :as nodejs])
(require '[clojure.test :as test])
(require '[mikron.test])
(nodejs/enable-util-print!)
(defmethod test/report [::test/default :summary] [{:keys [fail error] :as summary}]
(println "Test summary: " summary)
(.exit nodejs/process (if (= 0 fail error) 0 1)))
(test/run-tests 'mik... | Fix unmatched delimiter in lumo test script | Fix unmatched delimiter in lumo test script
| Clojure | epl-1.0 | moxaj/mikron,moxaj/mikron |
d3f058e112a15849b6109f7961979ae9b332dd81 | metlog-vault/src-server/metlog_vault/scheduler.clj | metlog-vault/src-server/metlog_vault/scheduler.clj | (ns metlog-vault.scheduler
(:use metlog-common.core)
(:require [clojure.tools.logging :as log]))
(defn start [ ]
(doto (it.sauronsoftware.cron4j.Scheduler.)
(.setDaemon true)
(.start)))
(defn schedule-job [ scheduler desc cron job-fn ]
(do
(log/info "Background job scheduled (cron:" cron "):" des... | (ns metlog-vault.scheduler
(:use metlog-common.core)
(:require [clojure.tools.logging :as log]))
(defn start [ ]
(doto (it.sauronsoftware.cron4j.Scheduler.)
(.setDaemon true)
(.start)))
(defn schedule-job [ scheduler desc cron job-fn ]
(let [ job-fn (exception-barrier job-fn (str "scheduled job:" desc... | Correct a bug that prevented scheduled jobs fromw orking at all. | Correct a bug that prevented scheduled jobs fromw orking at all.
| Clojure | epl-1.0 | mschaef/metlog |
567af9f503f8b1f3d488cad878887402069c70bf | project.clj | project.clj | (defproject onyx-app/lein-template "0.14.1.0"
:description "Onyx Leiningen application template"
:url "https://github.com/onyx-platform/onyx-template"
:license {:name "MIT License"
:url "http://choosealicense.com/licenses/mit/#"}
:repositories {"snapshots" {:url "https://clojars.org/repo"
... | (defproject onyx-app/lein-template "0.14.1.1-SNAPSHOT"
:description "Onyx Leiningen application template"
:url "https://github.com/onyx-platform/onyx-template"
:license {:name "MIT License"
:url "http://choosealicense.com/licenses/mit/#"}
:repositories {"snapshots" {:url "https://clojars.org/repo"
... | Prepare for next release cycle. | Prepare for next release cycle.
| Clojure | mit | onyx-platform/onyx-template |
cbfbdc910566f630f00bbccec49a917831951674 | project.clj | project.clj | (defproject org.onyxplatform/onyx-datomic "0.7.3-SNAPSHOT"
:description "Onyx plugin for Datomic"
:url "https://github.com/MichaelDrogalis/onyx-datomic"
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:dependencies [[org.clojure/clojure "1.7.0"]
... | (defproject org.onyxplatform/onyx-datomic "0.7.3-SNAPSHOT"
:description "Onyx plugin for Datomic"
:url "https://github.com/MichaelDrogalis/onyx-datomic"
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:dependencies [[org.clojure/clojure "1.7.0"]
... | Update dependency org.onyxplatform/onyx to version 0.7.3-20150828_152050-gd122e3e. | Update dependency org.onyxplatform/onyx to version 0.7.3-20150828_152050-gd122e3e.
Automatic commit by lein-traffic-control.
| Clojure | epl-1.0 | onyx-platform/onyx-datomic |
a7bced67c28d6a7dc96d6c64015d50c0eb1eb3a8 | project.clj | project.clj | (defproject onyx-plugin/lein-template "0.8.2.1"
:description "A Leiningen 2.0 template for new Onyx plugins"
:url "http://github.com/MichaelDrogalis/onyx-plugin"
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:repositories {"snapshots" {:url "https://cloja... | (defproject onyx-plugin/lein-template "0.8.2.2-SNAPSHOT"
:description "A Leiningen 2.0 template for new Onyx plugins"
:url "http://github.com/MichaelDrogalis/onyx-plugin"
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:repositories {"snapshots" {:url "http... | Prepare for next release cycle. | Prepare for next release cycle.
| Clojure | epl-1.0 | onyx-platform/onyx-plugin |
c4c87915ea9055eaa3c436e9eca66765192c30a0 | project.clj | project.clj | (defproject com.nomistech/clojure-the-language "0.1.0-SNAPSHOT"
:dependencies [[cheshire "5.8.0"]
[com.climate/claypoole "1.1.4"]
[com.taoensso/timbre "4.10.0" :exclusions [io.aviso/pretty
org.clojure/tools.reader]]
... | (defproject com.nomistech/clojure-the-language "0.1.0-SNAPSHOT"
:dependencies [[bidi "2.1.3" :exclusions [ring/ring-core]]
[cheshire "5.8.0"]
[com.climate/claypoole "1.1.4"]
[com.taoensso/timbre "4.10.0" :exclusions [io.aviso/pretty
... | Add `bidi` and `yada` dependencies | Add `bidi` and `yada` dependencies
| Clojure | epl-1.0 | simon-katz/nomis-clojure-the-language |
0d43faff805526fc769cc19bfaa6ec1f89cfc054 | project.clj | project.clj | (defproject onyx-app/lein-template "0.10.0.0-alpha7"
:description "Onyx Leiningen application template"
:url "https://github.com/onyx-platform/onyx-template"
:license {:name "MIT License"
:url "http://choosealicense.com/licenses/mit/#"}
:repositories {"snapshots" {:url "https://clojars.org/repo"
... | (defproject onyx-app/lein-template "0.10.0.0-SNAPSHOT"
:description "Onyx Leiningen application template"
:url "https://github.com/onyx-platform/onyx-template"
:license {:name "MIT License"
:url "http://choosealicense.com/licenses/mit/#"}
:repositories {"snapshots" {:url "https://clojars.org/repo"
... | Prepare for next release cycle. | Prepare for next release cycle.
| Clojure | mit | onyx-platform/onyx-template |
926a2961d32ccbaf669947c77a462e6846200b57 | project.clj | project.clj | (defproject onyx-app/lein-template "0.10.0.0-beta11"
:description "Onyx Leiningen application template"
:url "https://github.com/onyx-platform/onyx-template"
:license {:name "MIT License"
:url "http://choosealicense.com/licenses/mit/#"}
:repositories {"snapshots" {:url "https://clojars.org/repo"
... | (defproject onyx-app/lein-template "0.10.0.0-SNAPSHOT"
:description "Onyx Leiningen application template"
:url "https://github.com/onyx-platform/onyx-template"
:license {:name "MIT License"
:url "http://choosealicense.com/licenses/mit/#"}
:repositories {"snapshots" {:url "https://clojars.org/repo"
... | Prepare for next release cycle. | Prepare for next release cycle.
| Clojure | mit | onyx-platform/onyx-template |
814e4b638350e0f6beb2ef9768e730e9cc6bec84 | project.clj | project.clj | (defproject funcool/futura "0.1.0-SNAPSHOT"
:description "A basic building blocks for async programming."
:url "https://github.com/funcool/futura"
:license {:name "BSD (2 Clause)"
:url "http://opensource.org/licenses/BSD-2-Clause"}
:dependencies [[cats "0.4.0"]
[manifold "0.1.0"]
... | (defproject funcool/futura "0.1.0-SNAPSHOT"
:description "A basic building blocks for async programming."
:url "https://github.com/funcool/futura"
:license {:name "BSD (2 Clause)"
:url "http://opensource.org/licenses/BSD-2-Clause"}
:dependencies [[cats "0.4.0"]
[manifold "0.1.0"]
... | Set clojure version to 1.7-beta2 | Set clojure version to 1.7-beta2
| Clojure | bsd-2-clause | funcool/futura |
ee18f30ec846493b9b642c8d45f3b3d977431c91 | project.clj | project.clj | (defproject onyx-app/lein-template "0.12.0.0"
:description "Onyx Leiningen application template"
:url "https://github.com/onyx-platform/onyx-template"
:license {:name "MIT License"
:url "http://choosealicense.com/licenses/mit/#"}
:repositories {"snapshots" {:url "https://clojars.org/repo"
... | (defproject onyx-app/lein-template "0.12.0.1-SNAPSHOT"
:description "Onyx Leiningen application template"
:url "https://github.com/onyx-platform/onyx-template"
:license {:name "MIT License"
:url "http://choosealicense.com/licenses/mit/#"}
:repositories {"snapshots" {:url "https://clojars.org/repo"
... | Prepare for next release cycle. | Prepare for next release cycle.
| Clojure | mit | onyx-platform/onyx-template |
37458a1c28c9f8f992a4b2cc7a1ebce767675e17 | project.clj | project.clj | (defproject com.palletops/leaven "0.1.0-SNAPSHOT"
:description "A lightweight component library for clojure and clojurescript."
:url "https://github.com/palletops/leaven"
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:plugins [[com.keminglabs/cljx "0.4.0"... | (defproject com.palletops/leaven "0.1.0-SNAPSHOT"
:description "A lightweight component library for clojure and clojurescript."
:url "https://github.com/palletops/leaven"
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:plugins [[com.keminglabs/cljx "0.4.0"... | Add aliases for build jars and test | Add aliases for build jars and test
| Clojure | epl-1.0 | palletops/leaven |
b70e276934e3aad8d20792aca6b435c6632ff4a6 | project.clj | project.clj | (defproject cli4clj "1.2.0"
;(defproject cli4clj "1.2.1-SNAPSHOT"
:description "Create simple interactive CLIs for Clojure applications."
:url "https://github.com/ruedigergad/cli4clj"
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:dependencies [[org.cloju... | ;(defproject cli4clj "1.2.0"
(defproject cli4clj "1.2.1-SNAPSHOT"
:description "Create simple interactive CLIs for Clojure applications."
:url "https://github.com/ruedigergad/cli4clj"
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:dependencies [[org.cloju... | Switch back to snapshot version. | Switch back to snapshot version.
| Clojure | epl-1.0 | ruedigergad/cli4clj |
9e6676df91a07ab6c86ce4cc286c8688c3bf7e49 | project.clj | project.clj | (defproject org.onyxplatform/onyx-datomic "0.7.5"
:description "Onyx plugin for Datomic"
:url "https://github.com/MichaelDrogalis/onyx-datomic"
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:repositories {"snapshots" {:url "https://clojars.org/repo"
... | (defproject org.onyxplatform/onyx-datomic "0.7.6-SNAPSHOT"
:description "Onyx plugin for Datomic"
:url "https://github.com/MichaelDrogalis/onyx-datomic"
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:repositories {"snapshots" {:url "https://clojars.org/re... | Prepare for next release cycle. | Prepare for next release cycle.
| Clojure | epl-1.0 | onyx-platform/onyx-datomic |
bee94440a27f49bd3d1434233803a178e64a1f28 | src/doctopus/files/predicates.clj | src/doctopus/files/predicates.clj | (ns doctopus.files.predicates
"We've got a loooot of filtering to do.
Like, a lot.")
(defmulti is-type?
"Returns true if the type of the file matches the type given."
(fn [fobj regex] (class fobj)))
(defmethod is-type? java.lang.String
[file-string type-regex]
(if (re-find type-regex file-string)
tru... | (ns doctopus.files.predicates
"We've got a loooot of filtering to do.
Like, a lot.")
;; ### The `is-type' Multimethod
;; Dispatches on the type of an object which represents a file; returns a string
;; representation of the fully qualified path of that file, suitable for
;; regexing
(defmulti is-type?
"Returns... | Tidy up, add an html? predicate | Tidy up, add an html? predicate
| Clojure | epl-1.0 | Gastove/doctopus |
1a6dbc73f3bd5e7dcf1dfc0de09b28cfb06602a3 | test/minijava/test_munch.clj | test/minijava/test_munch.clj | (ns minijava.test-munch
(:use (minijava gas ir munch)
clojure.test))
(deftest test-Move-Mem-Binop
(let [
t1 (Temp (minijava.ir.temp.Temp.))
t2 (Temp (minijava.ir.temp.Temp.))
tree (Move (Mem (BinaryOp :+ (Const 2) t1)) t2)]
(is (= (select tree)
'(Movl (MEMORY t1 (C... | (ns minijava.test-munch
(:use (minijava gas ir munch)
clojure.test))
(deftest test-Move-Mem-Binop
(let [
t1 (Temp (minijava.ir.temp.Temp.))
t2 (Temp (minijava.ir.temp.Temp.))
tree (Move (Mem (BinaryOp :+ (Const 2) t1)) t2)]
(is (= (select tree)
'(Movl (MEMORY t1 (C... | Fix missing paren in test | Fix missing paren in test
| Clojure | mit | mikedouglas/MiniJava,mikedouglas/MiniJava |
caaada7ae6d305fd179020da9815a03258da42b1 | src/ui/core.cljs | src/ui/core.cljs | (ns ui.core
(:require [figwheel.client :as fw :include-macros true]
[reagent.core :as reagent :refer [atom]]))
(enable-console-print!)
(fw/watch-and-reload
:websocket-url "ws://localhost:3449/figwheel-ws"
:jsload-callback (fn [] (print "reloaded")))
(defonce state (atom 0))
(defn root-component ... | (ns ui.core
(:require [figwheel.client :as fw :include-macros true]
[reagent.core :as reagent :refer [atom]]
[clojure.string :as string]))
(enable-console-print!)
(fw/watch-and-reload
:websocket-url "ws://localhost:3449/figwheel-ws"
:jsload-callback (fn [] (print "reloaded")))
(defonc... | Add ability to execute shell command | Add ability to execute shell command
| Clojure | mit | Gonzih/cljs-electron,Gonzih/cljs-electron |
7b8c224fe5397ee9ff59ab60b5cf66015541383c | project/analyze-data/src/analyze_data/tf_idf/term_frequency.clj | project/analyze-data/src/analyze_data/tf_idf/term_frequency.clj | (ns analyze-data.tf-idf.term-frequency)
(defn term-frequency
"Return a map from term to number of times it appears in terms."
[terms]
(reduce (fn [m term] (assoc m term (inc (get m term 0)))) {} terms))
(defn calc-normalized-term-frequency
"Normalize term-frequency based on max-term-frequency."
[term-freque... | (ns analyze-data.tf-idf.term-frequency)
(defn term-frequency
"Return a map from term to number of times it appears in terms."
[terms]
(frequencies terms))
(defn calc-normalized-term-frequency
"Normalize term-frequency based on max-term-frequency."
[term-frequency max-term-frequency]
(+ 0.5 (* 0.5 (/ term-... | Replace implementation of term-frequency with frequencies function. | Replace implementation of term-frequency with frequencies function.
| Clojure | mit | dylanfprice/stanfordml,dylanfprice/stanfordml |
4d3b2bad3cd34aa36df2da266e71e277615ef974 | src/cljs/decktouch/card-input.cljs | src/cljs/decktouch/card-input.cljs | (ns decktouch.card-input
(:require [reagent.core :as reagent :refer [atom]]
[ajax.core :refer [GET]]))
(def llist
[{:name "foo"}
{:name "bar"}
{:name "lol"}])
(defn card-input [the-cards]
(let [get-val #(.-value (.getElementById js/document "the-input"))
reset-input #(set! (.-... | (ns decktouch.card-input
(:require [reagent.core :as reagent :refer [atom]]
[ajax.core :refer [GET]]))
(defn card-input [the-cards]
(let [get-val #(.-value (.getElementById js/document "the-input"))
reset-input #(set! (.-value (.getElementById js/document
... | Add autocomplete that queries serverside card master | Add autocomplete that queries serverside card master
| Clojure | epl-1.0 | Pance/decktouch,Pance/decktouch |
8be568d10c5bf99ee3a0de8256c20f6ddfb779b9 | services/get-comparison-files.clj | services/get-comparison-files.clj |
{:name "get-comparison-files"
:path ""
:repeat true
:generator true
:func (let [bam-ot-pairs (volatile! :nyi)]
(fn[eid comp-filename rep?]
(when (= @bam-ot-pairs :nyi)
(vswap! bam-ot-pairs
(fn[_] (htrs/get-comparison-files eid comp-filename rep?))))
... |
{:name "get-comparison-files"
:path ""
:repeat true
:generator true
:func (let [cmpgrps (volatile! :nyi)]
(fn[eid comp-filename opt?]
(when (= @cmpgrps :nyi)
(vswap! cmpgrps
(fn[_]
(cmn/get-comparison-files
(cmn/ge... | Add dispatching support for exp type | Add dispatching support for exp type
| Clojure | mit | jsa-aerial/aerobio,jsa-aerial/aerobio,jsa-aerial/aerobio,jsa-aerial/aerobio,jsa-aerial/aerobio |
a843de3ad71a331cdd66f2d61490d22ac6397978 | src/smallex/reductions.clj | src/smallex/reductions.clj | (ns smallex.reductions
(:require [clojure.walk :as walk]))
(defn- find-alias-deps
"Returns a set of alias deps, given an expression."
[expr]
(case (:type expr)
(:string :char-set) #{}
:symbol #{(:value expr)}
:op (set (mapcat find-alias-deps (:args expr)))))
(defn check-cyclic-aliases
"Given a g... | (ns smallex.reductions
(:require [clojure.set :as set]
[clojure.walk :as walk]))
(defn- find-alias-deps
"Returns a set of alias deps, given an expression."
[expr]
(case (:type expr)
(:string :char-set) #{}
:symbol #{(:value expr)}
:op (apply set/union (map find-alias-deps (:args expr)))... | Replace `set mapcat` to `apply union map`. | Replace `set mapcat` to `apply union map`.
| Clojure | epl-1.0 | hyPiRion/smallex |
3ba9e0f1bdb4401dbbf2feed937bbe5e55c949bd | src/riemann/keenio.clj | src/riemann/keenio.clj | (ns riemann.keenio
"Forwards events to Keen IO"
(:require [clj-http.client :as client])
(:require [cheshire.core :as json]))
(def ^:private event-url
"https://api.keen.io/3.0/projects/")
(defn- post
"POST to Keen IO."
[collection project-id write-key request]
(def final-event-url
(str event-url pro... | (ns riemann.keenio
"Forwards events to Keen IO"
(:require [clj-http.client :as client])
(:require [cheshire.core :as json]))
(def ^:private event-url
"https://api.keen.io/3.0/projects/")
(defn- post
"POST to Keen IO."
[collection project-id write-key request]
(let [final-event-url
(str event-url pr... | Use let, not def. Fix docs | Use let, not def. Fix docs
| Clojure | epl-1.0 | bg451/riemann,yeller/riemann,pyr/riemann,pharaujo/riemann,mirwan/riemann,mirwan/riemann,DasAllFolks/riemann,bfritz/riemann,DasAllFolks/riemann,irudyak/riemann,bwilber/riemann,rhysr/riemann,forter/riemann,zamaterian/riemann,Anvil/riemann,yeller/riemann,alq666/riemann,rekhajoshm/riemann,mbuczko/riemann,rhysr/riemann,timb... |
66a7e03f1716ef65951c861a0fc8482d6a654c2b | src/servisne_info/scrape/ns_rs.clj | src/servisne_info/scrape/ns_rs.clj | (ns servisne-info.scrape.ns-rs
(:use servisne-info.scrape.common)
(:require [net.cgrand.enlive-html :as en]
[clojure.string :as s]))
; Site description
(def info-site
{:url "http://www.021.rs"
:links-path "/novi-sad/servisne-informacije.html"})
; Private
(defn- info-page-title [html]
(s/trim ... | (ns servisne-info.scrape.ns-rs
(:use servisne-info.scrape.common)
(:require [net.cgrand.enlive-html :as en]
[clojure.string :as s]))
; Site description
(def info-site
{:url "http://www.021.rs"
:links-path "/Novi-Sad/Servisne-informacije"})
; Private
(defn- info-page-title [html]
(s/trim (firs... | Change url for scraping service informations | Change url for scraping service informations
| Clojure | mit | darkofabijan/servisne.info,strika/servisne.info,strika/servisne.info,darkofabijan/servisne.info |
ad66a60143c988317a1684c865ebd03ddf3f8314 | src/docs/om_mantras/docs.cljs | src/docs/om_mantras/docs.cljs | (ns om-mantras.docs
(:require [devcards.core :refer-macros [defcard start-devcard-ui!]]
[om-mantras.docs.selectable]
[om-mantras.docs.sortable]))
(enable-console-print!)
(start-devcard-ui!)
(defcard "# Hello again")
| (ns om-mantras.docs
(:require [devcards.core :refer-macros [defcard start-devcard-ui!]]
[om-mantras.docs.selectable]
[om-mantras.docs.sortable]))
(enable-console-print!)
(start-devcard-ui!)
(defcard
"# Om Mantras
Om Mantras are a collection of truly reusable, generic components for
O... | Add generic documentation about the project to the devcards | Add generic documentation about the project to the devcards
| Clojure | agpl-3.0 | Jannis/om-mantras,Jannis/om-mantras |
cc5a3886526af695ecbf503566b8b166b38c43fe | src/uxbox/main.clj | src/uxbox/main.clj | (ns uxbox.main
(:require [clojure.tools.namespace.repl :as repl]
[mount.core :as mount]
[uxbox.config :as cfg]
[uxbox.migrations]
[uxbox.persistence]
[uxbox.frontend])
(:gen-class))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;... | (ns uxbox.main
(:require [clojure.tools.namespace.repl :as repl]
[mount.core :as mount]
[buddy.core.codecs :as codecs]
[buddy.core.nonce :as nonce]
[uxbox.config :as cfg]
[uxbox.migrations]
[uxbox.persistence]
[uxbox.frontend])
(:ge... | Add helper for generate random secret key. | Add helper for generate random secret key.
| Clojure | mpl-2.0 | uxbox/uxbox-backend,uxbox/uxbox-backend |
68229b83124d7b41e05813d6c92cd1b230ecd358 | exercises/robot-name/src/example.clj | exercises/robot-name/src/example.clj | (ns robot-name)
(def ^:private random (java.util.Random.))
(def ^:private letters (map char (range 65 91)))
(defn- generate-name []
(str (apply str (take 2 (shuffle letters)))
(+ 100 (.nextInt random 899))))
(defn robot []
{:name (atom (generate-name))})
(defn robot-name [robot]
@(:name robot))
(defn r... | (ns robot-name)
(def ^:private random (java.util.Random.))
(def ^:private letters (map char (range 65 91)))
(defn- generate-name []
(str (apply str (take 2 (shuffle letters)))
(+ 100 (.nextInt random 899))))
(defn robot []
(atom {:name (generate-name)}))
(defn robot-name [robot]
(:name @robot))
(defn r... | Make the whole robot an atom in robot-name | Make the whole robot an atom in robot-name
| Clojure | mit | exercism/xclojure,querenker/xclojure,querenker/xclojure,exercism/xclojure |
6201109bfc2415dade3b53a75fecf7a428d3538a | src/whitman/config.clj | src/whitman/config.clj | (ns whitman.config
(:require [clojure.data.json :as json]
[whitman.utils :as utils]))
(def ^:private default-user-agent
(str "whitman/" utils/version))
(defn ^:private format-config [cfg]
(let [user-agent (if (contains? cfg "user-agent")
(format (get cfg "user-agent") utils/vers... | (ns whitman.config
(:require [clojure.data.json :as json]
[whitman.utils :as utils]))
(def ^:private default-user-agent
(str "whitman/" utils/version))
(defn ^:private user-agent [cfg]
(if (contains? cfg "user-agent")
(format (get cfg "user-agent") utils/version)
default-user-agent))
(defn ... | Break let statement into separate function | Break let statement into separate function
| Clojure | bsd-3-clause | mdippery/whitman |
4007fcd84b4e786b93453833bb2e4ddc085f531c | project.clj | project.clj | (defproject buddy/buddy-hashers "0.6.0"
:description "A collection of secure password hashers for Clojure"
:url "https://github.com/funcool/buddy-hashers"
:license {:name "Apache 2.0"
:url "http://www.apache.org/licenses/LICENSE-2.0"}
:dependencies [[org.clojure/clojure "1.6.0" :scope "provided"]
... | (defproject buddy/buddy-hashers "0.6.0"
:description "A collection of secure password hashers for Clojure"
:url "https://github.com/funcool/buddy-hashers"
:license {:name "Apache 2.0"
:url "http://www.apache.org/licenses/LICENSE-2.0"}
:dependencies [[org.clojure/clojure "1.7.0" :scope "provided"]
... | Set default clojure version to 1.7.0 | Set default clojure version to 1.7.0
| Clojure | apache-2.0 | funcool/buddy-hashers,rorygibson/buddy-hashers,rorygibson/buddy-hashers,funcool/buddy-hashers |
af0f116960a515584767e6b1a65a6f150f13e9f3 | project.clj | project.clj | (defproject onyx-app/lein-template "0.10.0.0-rc1"
:description "Onyx Leiningen application template"
:url "https://github.com/onyx-platform/onyx-template"
:license {:name "MIT License"
:url "http://choosealicense.com/licenses/mit/#"}
:repositories {"snapshots" {:url "https://clojars.org/repo"
... | (defproject onyx-app/lein-template "0.10.0.0-SNAPSHOT"
:description "Onyx Leiningen application template"
:url "https://github.com/onyx-platform/onyx-template"
:license {:name "MIT License"
:url "http://choosealicense.com/licenses/mit/#"}
:repositories {"snapshots" {:url "https://clojars.org/repo"
... | Prepare for next release cycle. | Prepare for next release cycle.
| Clojure | mit | onyx-platform/onyx-template |
05a7f4c6319f032a45dbc0d92b49febafa02b1a4 | project.clj | project.clj | (defproject ci-test "0.1.0-SNAPSHOT"
:description "FIXME: write description"
:url "http://example.com/FIXME"
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:dependencies [[org.clojure/clojure "1.8.0"]])
| (defproject ci-test "0.1.0-SNAPSHOT"
:description "FIXME: write description"
:url "http://example.com/FIXME"
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:dependencies [[org.clojure/clojure "1.8.0"]]
:repositories [["releases" {:url "https://clojars.or... | Add Clojar deployment repository for releases | Add Clojar deployment repository for releases
| Clojure | epl-1.0 | HughPowell/ci-test |
3f6a70a95e4b4312716e4049fc590142aab4ff4a | project.clj | project.clj | (defproject mvxcvi/blobble "0.1.0-SNAPSHOT"
:description "Content-addressed data storage interface."
:url "https://github.com/greglook/blobble"
:license {:name "Public Domain"
:url "http://unlicense.org/"}
:deploy-branches ["master"]
:plugins
[[lein-cloverage "1.0.2"]]
:dependencies
[[byt... | (defproject mvxcvi/blobble "0.1.0-SNAPSHOT"
:description "Content-addressed data storage interface."
:url "https://github.com/greglook/blobble"
:license {:name "Public Domain"
:url "http://unlicense.org/"}
:deploy-branches ["master"]
:plugins
[[lein-cloverage "1.0.2"]]
:dependencies
[[byt... | Use release version of multihash lib. | Use release version of multihash lib.
| Clojure | unlicense | greglook/blobble,greglook/blocks,greglook/blobble |
72cbff38cb59c45f9db4e2de654555ce03250856 | project.clj | project.clj | (defproject onyx-app/lein-template "0.10.0.0-beta2"
:description "Onyx Leiningen application template"
:url "https://github.com/onyx-platform/onyx-template"
:license {:name "MIT License"
:url "http://choosealicense.com/licenses/mit/#"}
:repositories {"snapshots" {:url "https://clojars.org/repo"
... | (defproject onyx-app/lein-template "0.10.0.0-SNAPSHOT"
:description "Onyx Leiningen application template"
:url "https://github.com/onyx-platform/onyx-template"
:license {:name "MIT License"
:url "http://choosealicense.com/licenses/mit/#"}
:repositories {"snapshots" {:url "https://clojars.org/repo"
... | Prepare for next release cycle. | Prepare for next release cycle.
| Clojure | mit | onyx-platform/onyx-template |
2a2ae0cf2a959ce853f7c40ca1cf35ff8ef0a35a | src/onyx/plugin/bench_plugin.clj | src/onyx/plugin/bench_plugin.clj | (ns onyx.plugin.bench-plugin
(:require [clojure.core.async :refer [chan >!! <!! close! alts!! timeout]]
[clojure.data.fressian :as fressian]
[onyx.peer.pipeline-extensions :as p-ext]))
(defmethod p-ext/read-batch :generator
[{:keys [onyx.core/task-map] :as event}]
(let [batch-size (:onyx/... | (ns onyx.plugin.bench-plugin
(:require [clojure.core.async :refer [chan >!! <!! close! alts!! timeout]]
[clojure.data.fressian :as fressian]
[onyx.peer.pipeline-extensions :as p-ext]))
(def hundred-bytes
(into-array Byte/TYPE (range 100)))
(defmethod p-ext/read-batch :generator
[{:keys ... | Make segments around 100 bytes each. | Make segments around 100 bytes each.
| Clojure | epl-1.0 | onyx-platform/onyx-benchmark,onyx-platform/onyx-benchmark,onyx-platform/onyx-benchmark |
55903db8d5ed049a328705d209a1b47a9aa5c97a | src/todo_repl_webapp/handler.clj | src/todo_repl_webapp/handler.clj | (ns todo-repl-webapp.handler
(:require [compojure.core :refer :all]
[compojure.handler :as handler]
[compojure.route :as route]
[cemerick.friend :as friend]
(cemerick.friend [workflows :as workflows]
[credentials :as credentials])
... | (ns todo-repl-webapp.handler
(:require [compojure.core :refer :all]
[compojure.handler :as handler]
[compojure.route :as route]
[cemerick.friend :as friend]
(cemerick.friend [workflows :as workflows]
[credentials :as credentials])
... | Add login uri to authentication wrapper | Add login uri to authentication wrapper
| Clojure | mit | Pance/todo-repl-webapp |
60762e1295324c06b2eea37f31ab138bc0c9ddf9 | src/cljs/robot_kata/image.cljs | src/cljs/robot_kata/image.cljs | (ns robot-kata.image)
(defn get-2d-context [canvas]
(.getContext canvas "2d") )
(defn get-color-name [color]
(let [threshold 192]
(cond (and (> (color :r) threshold) (> (color :g) threshold) (> (color :b) threshold)) "white"
(and (> (color :r) threshold) (> (color :g) threshold)) ... | (ns robot-kata.image)
(defn get-2d-context [canvas]
(.getContext canvas "2d") )
(defn get-color-name [color]
(let [threshold 128]
(cond (and (> (color :r) threshold) (> (color :g) threshold) (> (color :b) threshold)) "white"
(and (> (color :r) threshold) (> (color :g) threshold)) ... | Improve threshold for determining color name | Improve threshold for determining color name
| Clojure | epl-1.0 | ideal-knee/robot-kata |
5f07f2f57241c71989c4b14b17e18bbd69d0fd8f | .lein/profiles.clj | .lein/profiles.clj | {:user {:plugins [[jonase/eastwood "0.2.0"]
[lein-kibit "0.0."]]}}
| {:user {:plugins [[jonase/eastwood "0.2.0"]
[lein-kibit "0.0.8"]]}}
| Correct typo in lein-kibit version | Correct typo in lein-kibit version
| Clojure | mit | lpil/vimrc |
f47a05eaf2783dbb488a231749929e928654b71d | src/leiningen/deps.clj | src/leiningen/deps.clj | (ns leiningen.deps
(:require [lancet])
(:use [leiningen]
[clojure.contrib.java-utils :only [file]])
(:import [org.apache.maven.model Dependency]
[org.apache.maven.artifact.ant DependenciesTask]))
(defn- make-dependency [[group name version]]
(doto (Dependency.)
(.setGroupId group)
(.... | (ns leiningen.deps
(:require [lancet])
(:use [leiningen]
[clojure.contrib.java-utils :only [file]])
(:import [org.apache.maven.model Dependency]
[org.apache.maven.artifact.ant DependenciesTask]
[org.apache.tools.ant.util FlatFileNameMapper]))
(defn- make-dependency [[group name vers... | Put jars directly in lib/ instead of nesting. | Put jars directly in lib/ instead of nesting.
| Clojure | epl-1.0 | 0/leiningen,0/leiningen,ato/leiningen |
442216d2d2f2ae32457f7313ee6ab3bb70e5ded9 | examples/todomvc/project.clj | examples/todomvc/project.clj | (defproject todomvc-re-frame "0.10.10-SNAPSHOT"
:dependencies [[org.clojure/clojure "1.10.1"]
[org.clojure/clojurescript "1.10.520"
:exclusions [com.google.javascript/closure-compiler-unshaded
org.clojure/google-closure-library]]
... | (defproject todomvc-re-frame "0.10.10-SNAPSHOT"
:dependencies [[org.clojure/clojure "1.10.1"]
[org.clojure/clojurescript "1.10.520"
:exclusions [com.google.javascript/closure-compiler-unshaded
org.clojure/google-closure-library]]
... | Add more paths to :clean-targets for todomvc example | Add more paths to :clean-targets for todomvc example
| Clojure | mit | Day8/re-frame,Day8/re-frame,Day8/re-frame |
0e70116805a7446ac562c02659c94c7b4487b91f | src/aerobio/params.clj | src/aerobio/params.clj | (ns aerobio.params)
(def params (atom {}))
(defn param-ks []
(keys @params))
(defn param-set [] @params)
(defn get-params [& ks]
(if (= 1 (count ks))
(@params (first ks))
(mapv @params ks)))
| (ns aerobio.params)
(def params (atom {}))
(defn param-ks []
(keys @params))
(defn param-set [] @params)
(defn get-params [& ks]
(cond
(and (= 1 (count ks)) (vector? (first ks))) (get-in @params (first ks))
(= 1 (count ks)) (@params (first ks))
:else (mapv @params ks)))
| Add capability for nested gets | Add capability for nested gets
| Clojure | mit | jsa-aerial/aerobio,jsa-aerial/aerobio,jsa-aerial/aerobio,jsa-aerial/aerobio,jsa-aerial/aerobio |
c6449c7fa2f390cc60ee4428c39d92a055b6617a | src/braid/search/ui/search_bar.cljs | src/braid/search/ui/search_bar.cljs | (ns braid.search.ui.search-bar
(:require
[re-frame.core :refer [subscribe dispatch]]
[braid.core.client.routes :as routes]
[braid.lib.color :as color]))
(defn search-bar-view
[]
(let [search-query @(subscribe [:braid.search/query])]
[:div.search-bar
[:input {:type "text"
:place... | (ns braid.search.ui.search-bar
(:require
[reagent.core :as r]
[re-frame.core :refer [subscribe dispatch]]
[braid.core.client.routes :as routes]
[braid.lib.color :as color]))
(defn search-bar-view
[]
(r/with-let [search-query (r/atom @(subscribe [:braid.search/query]))]
[:div.search-bar
[:inp... | Make search bar more responsive to quick typing | Make search bar more responsive to quick typing
Use local state for search query input, in addition to dispatching;
just dispatching and referring to the sub can drop keystrokes and is
generally annoying when typing quickly
| Clojure | agpl-3.0 | rafd/braid,rafd/braid,braidchat/braid,braidchat/braid |
95b934aeded980b2a50303ff0585228d5fa11022 | ring-core/project.clj | ring-core/project.clj | (defproject ring/ring-core "1.3.2"
:description "Ring core libraries."
:url "https://github.com/ring-clojure/ring"
:scm {:dir ".."}
:license {:name "The MIT License"
:url "http://opensource.org/licenses/MIT"}
:dependencies [[org.clojure/clojure "1.3.0"]
[org.clojure/tools.reader "... | (defproject ring/ring-core "1.3.2"
:description "Ring core libraries."
:url "https://github.com/ring-clojure/ring"
:scm {:dir ".."}
:license {:name "The MIT License"
:url "http://opensource.org/licenses/MIT"}
:dependencies [[org.clojure/clojure "1.3.0"]
[org.clojure/tools.reader "... | Update clj-time dependency to 0.9.0 | Update clj-time dependency to 0.9.0
| Clojure | mit | suligap/ring,kirasystems/ring,ieure/ring,tchagnon/ring,meowcakes/ring,ring-clojure/ring,povloid/ring,ring-clojure/ring |
92227465e81f71241c86e3b0121829cf9b323c3a | src/day8/re_frame/trace/preload.cljs | src/day8/re_frame/trace/preload.cljs | (ns day8.re-frame.trace.preload
(:require [day8.re-frame.trace :as trace]
[mranderson047.re-frame.v0v10v2.re-frame.core :as rf]))
;; Use this namespace with the :preloads compiler option to perform the necessary setup for enabling tracing:
;; {:compiler {:preloads [day8.re-frame.trace.preload] ...}}
(rf... | (ns day8.re-frame.trace.preload
(:require [day8.re-frame.trace :as trace]
[mranderson047.re-frame.v0v10v2.re-frame.core :as rf]))
;; Use this namespace with the :preloads compiler option to perform the necessary setup for enabling tracing:
;; {:compiler {:preloads [day8.re-frame.trace.preload] ...}}
(js... | Add warning for people that upgrade to newer versions | Add warning for people that upgrade to newer versions
If someone used something like lein-ancient to upgrade their libraries,
they might not realise that re-frame-trace has been renamed to
re-frame-10x. This commit will log a warning every time it is loaded, to
tell people that they should use the new 10x version.
| Clojure | mit | Day8/re-frame-trace |
dd88b0cd1a0445ef66354456ce7bb65b63fd4032 | frontend/utils.clj | frontend/utils.clj | (ns frontend.utils)
(defmacro inspect
"prints the expression '<name> is <value>', and returns the value"
[value]
`(do
(let [name# (quote ~value)
result# ~value]
(print (pr-str name#) "is" (pr-str result#))
result#)))
(defmacro timing
"Evaluates expr and prints the label and the t... | (ns frontend.utils)
(defmacro inspect
"prints the expression '<name> is <value>', and returns the value"
[value]
`(do
(let [name# (quote ~value)
result# ~value]
(print (pr-str name#) "is" (pr-str result#))
result#)))
(defmacro timing
"Evaluates expr and prints the label and the t... | Add a little macro to reduce some of the om component boilerplate. | Add a little macro to reduce some of the om component boilerplate.
| Clojure | epl-1.0 | RayRutjes/frontend,circleci/frontend,prathamesh-sonpatki/frontend,circleci/frontend,RayRutjes/frontend,prathamesh-sonpatki/frontend,circleci/frontend |
e7c8fc24b64d3a94ddf77783f37ae79dcbe2771a | test/com/hypirion/smallex/test/lexer.clj | test/com/hypirion/smallex/test/lexer.clj | (ns com.hypirion.smallex.test.lexer
(:require [clojure.java.io :as io]
[clojure.pprint :refer [pprint]])
(:use [clojure.test])
(:import (com.hypirion.smallex SMLXLexer)))
(deftest test-read
(with-open [rdr (io/reader (io/resource "clojure.smlx"))]
(is (try
(doall (iterator-seq (SMLXLe... | (ns com.hypirion.smallex.test.lexer
(:require [clojure.java.io :as io]
[clojure.pprint :refer [pprint]])
(:use [clojure.test])
(:import (com.hypirion.smallex SMLXLexer)))
(deftest test-read
(with-open [rdr (io/reader (io/resource "clojure.smlx"))]
(is (not-any? #(= :error (:type %)) (iterator-s... | Check for error items in SMLXLexer test. | Check for error items in SMLXLexer test.
The SMLXLexer doesn't throw any exceptions, but return error items.
| Clojure | epl-1.0 | hyPiRion/smallex |
ff560bc8f24352c8ef8142b5f4580704bdfc6d03 | leap/leap_test.clj | leap/leap_test.clj | (ns leap.test (:require [clojure.test :refer :all]))
(load-file "leap_year.clj")
(deftest vanilla-leap-year
(is (leap-year? 1996)))
(deftest any-old-year
(is (not (leap-year? 1997))))
(deftest century
(is (not (leap-year? 1900))))
(deftest exceptional-century
(is (leap-year? 2400)))
(run-tests)
| (ns leap.test (:require [clojure.test :refer :all]))
(load-file "leap.clj")
(deftest vanilla-leap-year
(is (leap/leap-year? 1996)))
(deftest any-old-year
(is (not (leap/leap-year? 1997))))
(deftest century
(is (not (leap/leap-year? 1900))))
(deftest exceptional-century
(is (leap/leap-year? 2400)))
(run-tes... | Rename solution to leap.clj & prefix calls with ns | Rename solution to leap.clj & prefix calls with ns
| Clojure | mit | exercism/xclojure,wobh/xclojure,querenker/xclojure,yurrriq/xclojure,querenker/xclojure,canweriotnow/xclojure,exercism/xclojure |
045d5bef4b9e8dff2aae4187afb1fee3e23a1696 | resources/rest-service/cloudify/triggers/execute_workflow.clj | resources/rest-service/cloudify/triggers/execute_workflow.clj | (fn execute-workflow
[ctx]
(let [deployment-id (:deployment-id ctx)
parameters (:trigger-parameters ctx)
manager-ip (or (System/getenv "MANAGEMENT_IP") "127.0.0.1")
raw-manager-rest-port (or (System/getenv "MANAGER_REST_PORT") "80")
manager-res... | (fn execute-workflow
[ctx]
(let [deployment-id (:deployment-id ctx)
parameters (:trigger-parameters ctx)
node-id (:node-id ctx)
manager-ip (or (System/getenv "MANAGEMENT_IP") "127.0.0.1")
raw-manager-rest-port (or (System/getenv "... | Check if node is started before triggering a workflow | Check if node is started before triggering a workflow
| Clojure | apache-2.0 | cloudify-cosmo/cloudify-manager,konradxyz/dev_fileserver,cloudify-cosmo/cloudify-manager,konradxyz/cloudify-manager,codilime/cloudify-manager,geokala/cloudify-manager,cloudify-cosmo/cloudify-manager,codilime/cloudify-manager,isaac-s/cloudify-manager,geokala/cloudify-manager,codilime/cloudify-manager,isaac-s/cloudify-ma... |
85de5357455c5870270fe860a2d93ed4f4643e5c | src/whitman/writer.clj | src/whitman/writer.clj | (ns whitman.writer
(:require [monger.collection :as mc]
[whitman.db :as db]))
(defmulti write (fn [writer cfg query docs] writer))
(defmethod write :db [writer cfg query docs]
(mc/upsert (db/db cfg) (get cfg "collection") query docs {:upsert true}))
(defmethod write :console [writer cfg query docs]
(... | (ns whitman.writer
(:require [monger.collection :as mc]
[whitman.db :as db]))
(defmulti write (fn [writer cfg query docs] writer))
(defmethod write :db [writer cfg query docs]
(mc/upsert (db/db cfg) (get cfg "collection") query docs {:upsert true}))
(defmethod write :console [writer cfg query docs]
(... | Print both query and docs in debug mode | Print both query and docs in debug mode
| Clojure | bsd-3-clause | mdippery/whitman |
1b1869c0c3d6ff085c4366a8efa1286609f8d364 | project.clj | project.clj | (defproject jungerer "0.4.1"
:description "Clojure network/graph library wrapping JUNG"
:url "https://github.com/totakke/jungerer"
:license {:name "The BSD 3-Clause License"
:url "https://opensource.org/licenses/BSD-3-Clause"}
:min-lein-version "2.7.0"
:dependencies [[org.clojure/clojure "1.7.0"]
... | (defproject jungerer "0.4.2-SNAPSHOT"
:description "Clojure network/graph library wrapping JUNG"
:url "https://github.com/totakke/jungerer"
:license {:name "The BSD 3-Clause License"
:url "https://opensource.org/licenses/BSD-3-Clause"}
:min-lein-version "2.7.0"
:dependencies [[org.clojure/clojure ... | Prepare for next development iteration (0.4.2-SNAPSHOT) | Prepare for next development iteration (0.4.2-SNAPSHOT)
| Clojure | bsd-3-clause | totakke/jungerer |
0ee2c73d8656b97f80545c9009544c7ba0ffce7f | test/puppetlabs/kitchensink/testutils.clj | test/puppetlabs/kitchensink/testutils.clj | (ns puppetlabs.kitchensink.testutils
(:require [fs.core :as fs]))
(defn call-counter
"Returns a method that just tracks how many times it's called, and
with what arguments. That information is stored in metadata for the
method."
[]
(let [ncalls (ref 0)
arguments (ref [])]
(with-meta
(f... | (ns puppetlabs.kitchensink.testutils
(:require [fs.core :as fs]
[puppetlabs.kitchensink.core :as ks]))
(defn call-counter
"Returns a method that just tracks how many times it's called, and
with what arguments. That information is stored in metadata for the
method."
[]
(let [ncalls (ref 0)
... | Add macro for running a block of code w/o jvm shutdown hooks | Add macro for running a block of code w/o jvm shutdown hooks
| Clojure | apache-2.0 | camlow325/clj-kitchensink,mullr/clj-kitchensink |
10a9a75664ba0cc8a141e0eb0681072b5b64cdcd | src/lunchlotto/common/utils.clj | src/lunchlotto/common/utils.clj | (ns lunchlotto.common.utils
(:require [clojure.edn :as edn]
[environ.core :refer [env]]
[postmark.core :as pm]))
(defn parse-number
"Convert a string to a number. Return nil if not a number.
Since read-string is used, it checks the string against a regex to ensure the
string looks like... | (ns lunchlotto.common.utils
(:require [clojure.edn :as edn]
[environ.core :refer [env]]
[postmark.core :as pm]))
(defn parse-number
"Convert a string to a number. Return nil if not a number.
Since read-string is used, it checks the string against a regex to ensure the
string looks like... | Use edn/read-string when parsing numbers. | Use edn/read-string when parsing numbers.
| Clojure | epl-1.0 | bnadlerjr/lunchlotto,bnadlerjr/lunchlotto |
e515f7654f6aee38e3dd4773a4e8b52a452fd8f4 | src/mobile_patient/android/core.cljs | src/mobile_patient/android/core.cljs | (ns mobile-patient.android.core
(:require [reagent.core :as r :refer [atom]]
[re-frame.core :refer [subscribe dispatch dispatch-sync]]
[mobile-patient.routes :refer [routes]]
[mobile-patient.events]
[mobile-patient.subs]))
(def ReactNative (js/require "react-native"))
... | (ns mobile-patient.android.core
(:require [reagent.core :as r :refer [atom]]
[re-frame.core :refer [subscribe dispatch dispatch-sync]]
[mobile-patient.routes :refer [routes]]
[mobile-patient.events]
[mobile-patient.subs]))
(enable-console-print!)
(def ReactNative (js/... | Enable console print to fix prod app crash | Enable console print to fix prod app crash
| Clojure | epl-1.0 | Aidbox/mobile-patient,Aidbox/mobile-patient,Aidbox/mobile-patient,Aidbox/mobile-patient |
0c156be0f3453ae9117b248bdd494f8a4f9624b6 | example/build.boot | example/build.boot | (set-env!
:resource-paths #{"resources"}
:dependencies '[[org.clojure/clojure "1.8.0"]
[afrey/boot-asset-fingerprint "1.1.0-SNAPSHOT"]
[tailrecursion/boot-jetty "0.1.3" :scope "test"]])
(require
'[afrey.boot-asset-fingerprint :refer [asset-fingerprint]]
'[tailrecursion.boot-... | (set-env!
:resource-paths #{"resources"}
:dependencies '[[org.clojure/clojure "1.8.0"]
[afrey/boot-asset-fingerprint "1.1.0-SNAPSHOT"]
[tailrecursion/boot-jetty "0.1.3" :scope "test"]])
(require
'[afrey.boot-asset-fingerprint :refer [asset-fingerprint]]
'[tailrecursion.boot-... | Consolidate tasks in example file | Consolidate tasks in example file
| Clojure | mit | AdamFrey/boot-asset-fingerprint,AdamFrey/boot-asset-fingerprint |
cae879389fc148959350c187a65bb62d40e2557d | .lein/profiles.clj | .lein/profiles.clj | {:user {:plugins [;; Linters
[jonase/eastwood "0.2.3"]
[lein-ancient "0.6.10"]
[lein-bikeshed "0.3.0"]
[lein-cljfmt "0.5.3"]
[lein-kibit "0.1.2"]
[venantius/yagni "0.1.4"]
;; Documentation gene... | {:user {:plugins [;; Linters
[jonase/eastwood "0.2.3"]
[lein-ancient "0.6.10"]
[lein-bikeshed "0.3.0"]
[lein-cljfmt "0.5.3"]
[lein-kibit "0.1.2"]
[venantius/yagni "0.1.4"]
;; Documentation gene... | Hide the Clojure REPL in the Mac app switcher | Hide the Clojure REPL in the Mac app switcher
| Clojure | mit | raxod502/radian,raxod502/radian |
0751fcedba7a47e08c4b09fc19df7a9b1d142422 | Clojure/project.clj | Clojure/project.clj | (defproject org.omcljs/ambly "0.1.0"
:description "ClojureScript REPL into embedded JavaScriptCore."
:url "https://github.com/omcljs/ambly"
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:dependencies [[org.clojure/clojure "1.7.0-beta2"]
[... | (defproject org.omcljs/ambly "0.1.0"
:description "ClojureScript REPL into embedded JavaScriptCore."
:url "https://github.com/omcljs/ambly"
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:dependencies [[org.clojure/clojure "1.7.0-beta3"]
[... | Update Clojure and ClojureScript deps | Update Clojure and ClojureScript deps
1.7.0-beta3
0.0-3269
| Clojure | epl-1.0 | omcljs/ambly,jobez/ambly,bsvingen/ambly,jobez/ambly,domesticmouse/ambly,bsvingen/ambly,domesticmouse/ambly,omcljs/ambly |
6b1f1ca4623d42c4a75ff5a0f2c69ca38d4e9e06 | test/yada/trace_test.clj | test/yada/trace_test.clj | ;; Copyright © 2015, JUXT LTD.
(ns yada.trace-test
(:require
[clojure.java.io :as io]
[clojure.test :refer :all]
[ring.mock.request :refer [request]]
[yada.yada :as yada]
[juxt.iota :refer (given)]))
(deftest trace-test []
(testing "Normal operation"
(let [resource "Hello World!"
hand... | ;; Copyright © 2015, JUXT LTD.
(ns yada.trace-test
(:require
[clojure.java.io :as io]
[clojure.test :refer :all]
[ring.mock.request :refer [request]]
[yada.yada :as yada]
[juxt.iota :refer (given)]))
;; For now disable TRACE - need to think a better way of returning a d/success from the chain, prior ... | Disable TRACE test (for now) | Disable TRACE test (for now)
| Clojure | mit | mbutlerw/yada,thomas-shares/yada,delitescere/yada,delitescere/yada,delitescere/yada,mbutlerw/yada,juxt/yada,juxt/yada,thomas-shares/yada,mbutlerw/yada,juxt/yada |
b24c68d61dd4159529e24a02b259817448dff583 | project.clj | project.clj | (defproject mvxcvi/vault "0.3.0-SNAPSHOT"
:description "Content-addressable data store."
:url "https://github.com/greglook/vault"
:license {:name "Public Domain"
:url "http://unlicense.org/"}
:dependencies
[[byte-streams "0.1.10"]
[clj-time "0.7.0"]
[environ "0.5.0"]
[potemkin "0.3.4"]
... | (defproject mvxcvi/vault "0.3.0-SNAPSHOT"
:description "Content-addressable data store."
:url "https://github.com/greglook/vault"
:license {:name "Public Domain"
:url "http://unlicense.org/"}
:dependencies
[[byte-streams "0.1.10"]
[clj-time "0.7.0"]
[environ "0.5.0"]
[potemkin "0.3.4"]
... | Upgrade puget and prismatic/schema versions. | Upgrade puget and prismatic/schema versions.
| Clojure | unlicense | greglook/vault |
1154280cb5729bd3fb4024a705d594670a9b9952 | project.clj | project.clj | (defproject com.nomistech/clojure-the-language "0.1.0-SNAPSHOT"
:dependencies [[org.clojure/clojure "1.6.0"]
[org.clojure/core.match "0.3.0-alpha4"]
[org.clojure/core.async "0.1.346.0-17112a-alpha"]]
:profiles
{:dev {:dependencies [[midje "1.6.3"]]
:plugins [[lein-midje ... | (defproject com.nomistech/clojure-the-language "0.1.0-SNAPSHOT"
:dependencies [[org.clojure/clojure "1.6.0"]
[org.clojure/core.match "0.3.0-alpha4"]
[org.clojure/core.async "0.1.346.0-17112a-alpha"]]
:profiles
{:dev {:dependencies [[midje "1.6.3"]]
:plugins [[lein-midje ... | Remove unwanted dependency on tools.namespace. (Have that in user profile.) | Remove unwanted dependency on tools.namespace. (Have that in user profile.)
| Clojure | epl-1.0 | simon-katz/nomis-clojure-the-language |
54e74e4ab44d1fe5ac1ab865c308f9f78f242638 | src/server/clojure_template/templates/layouts.clj | src/server/clojure_template/templates/layouts.clj | (ns clojure-template.templates.layouts
(:require [environ.core :refer [env]]
[hiccup.page :refer [html5 include-css include-js]]
[ring.middleware.anti-forgery :refer [*anti-forgery-token*]]))
(defn application [& content]
(html5 [:head
[:meta {:charset "utf-8"}]
[:meta {... | (ns clojure-template.templates.layouts
(:require [environ.core :refer [env]]
[hiccup.page :refer [html5 include-css include-js]]))
(defn application [& content]
(html5 [:head
[:meta {:charset "utf-8"}]
[:meta {:http-equiv "X-UA-Compatible" :content "IE=edge"}]
[:meta {:nam... | Remove csrf token from template | Remove csrf token from template
| Clojure | epl-1.0 | hung-phan/clojure-template,hung-phan/clojure-template |
d68975277a0fd2edab9eea70802c3c43ef6c26b8 | src/refactor_nrepl/find_unbound.clj | src/refactor_nrepl/find_unbound.clj | (ns refactor-nrepl.find-unbound
(:require [clojure.set :as set]
[clojure.tools.analyzer.ast :refer [nodes]]
[refactor-nrepl
[analyzer :refer [ns-ast]]
[util :refer :all]]))
(defn find-unbound-vars [{:keys [file line column]}]
{:pre [(number? line)
(number?... | (ns refactor-nrepl.find-unbound
(:require [clojure.set :as set]
[clojure.tools.analyzer.ast :refer [nodes]]
[refactor-nrepl
[analyzer :refer [ns-ast]]
[util :refer :all]]))
(defn find-unbound-vars [{:keys [file line column]}]
{:pre [(number? line)
(number?... | Add missing file from last commit | Add missing file from last commit
| Clojure | epl-1.0 | grammati/refactor-nrepl,Peeja/refactor-nrepl,Peeja/refactor-nrepl,duncanmortimer/refactor-nrepl,duncanmortimer/refactor-nrepl,clojure-emacs/refactor-nrepl,luxbock/refactor-nrepl,clumsyjedi/refactor-nrepl,msgodf/refactor-nrepl,luxbock/refactor-nrepl,clumsyjedi/refactor-nrepl,grammati/refactor-nrepl,msgodf/refactor-nrepl... |
4d79ed14d2ccd044e4423491419df71a6b336871 | src/rsvp_backend/middleware/logging.clj | src/rsvp_backend/middleware/logging.clj | (ns rsvp-backend.middleware.logging
(:require [cheshire.core :as json]
[ring.util.response :as response]
[ring.util.request :as req]
[taoensso.timbre :as log]))
(def standard-ring-request-keys
[:server-port :server-name :remote-addr :uri :query-string :scheme
:headers :reques... | (ns rsvp-backend.middleware.logging
(:require [cheshire.core :as json]
[ring.util.response :as response]
[ring.util.request :as req]
[taoensso.timbre :as log]))
(def standard-ring-request-keys
[:server-port :server-name :remote-addr :uri :query-string :scheme
:headers :reques... | Remove request body parsing in middleware. | Remove request body parsing in middleware.
| Clojure | epl-1.0 | shaaza/rsvp-backend |
b4d972b4662e6c7da95aaecb5b72c6b8a742c8ce | src/datemo/init.clj | src/datemo/init.clj | (ns datemo.init
(:require
[environ.core :refer [env]]
[datemo.db :as db]))
(require '[clojure.pprint :refer [pprint]])
(defn prep-db [name]
(println "Database `" name "` exists?: " (db/db-exists name))
(if (db/db-exists name)
(db/connect name)
(do
(println "Database `" name "` does not exi... | (ns datemo.init
(:require
[environ.core :refer [env]]
[datemo.db :as db]))
(require '[clojure.pprint :refer [pprint]])
(defn prep-db [name]
{:pre [(not (nil? name))]}
(println "Database `" name "` exists?: " (db/db-exists name))
(if (db/db-exists name)
(db/connect name)
(do
(println "Dat... | Add assert for prep-db fn | Add assert for prep-db fn
| Clojure | epl-1.0 | ezmiller/datemo |
74aab7a2f87df6956948799793349525350fb1b3 | src/demo/web.clj | src/demo/web.clj | (ns demo.web
(:require [clojure.pprint :refer [pprint]]
[immutant.web :as web]
[ring.util.response :as ring-util]))
(defn echo-request
"Echoes the request back as a string."
[request]
(ring-util/response (with-out-str (pprint request))))
(defn -main
[& {:as args}]
(web/ru... | (ns demo.web
(:require [clojure.pprint :refer [pprint]]
[immutant.web :as web]
[immutant.web.javax :as javax]
[ring.middleware.resource :as ring-resource]
[ring.util.response :as ring-util]))
(defn echo-request
"Echoes the request ba... | Revert "Remove session counter example for now." | Revert "Remove session counter example for now."
This reverts commit f0e08f92a41ab95c8738389bfb784a93ae378efe.
| Clojure | apache-2.0 | FalseProtagonist/graphagora,immutant/feature-demo,jkutner/feature-demo,coopsource/feature-demo,FalseProtagonist/graphagora,jkutner/feature-demo,coopsource/feature-demo,coopsource/feature-demo,immutant/feature-demo,jkutner/feature-demo,immutant/feature-demo,FalseProtagonist/graphagora |
6b600b0cf7ff1b323a87128b91f13c131eb8d6eb | src/discuss/config.cljs | src/discuss/config.cljs | (ns discuss.config)
(def project "discuss")
(def user "Q2hyaXN0aWFu")
(def api {:host "http://localhost:4284/"
:init "api/cat-or-dog"
:base "api/"
:login "api/login"
:add {:add-start-statement "api/add/start_statement"
:add-start-premise "api/add/start... | (ns discuss.config)
(def project "discuss")
(def user "Q2hyaXN0aWFu")
(def api {:host "http://localhost:4284/"
:init "api/elektroautos"
:base "api/"
:login "api/login"
:add {:add-start-statement "api/add/start_statement"
:add-start-premise "api/add/sta... | Set defaults to german language | Set defaults to german language
| Clojure | mit | hhucn/discuss,hhucn/discuss |
d5e789890eba01adc996c2898447ac660e4c60dd | src/cljs/gtfve/controllers/controls.cljs | src/cljs/gtfve/controllers/controls.cljs | (ns gtfve.controllers.controls
(:require-macros [cljs.core.async.macros :refer [go go-loop]]
[gtfve.macros :refer [<?]])
(:require [om.core :as om]
[cljs.core.async :as async :refer [put! <! close!]]))
(defmulti control-event
(fn [event args state] event))
(defmethod control-event... | (ns gtfve.controllers.controls
(:require-macros [cljs.core.async.macros :refer [go go-loop]]
[gtfve.macros :refer [<?]])
(:require [om.core :as om]
[cljs.core.async :as async :refer [put! <! close!]]))
(defmulti control-event
(fn [event args state] event))
(defmethod control-event... | Fix get-in not returning cursor | Fix get-in not returning cursor | Clojure | epl-1.0 | alvinfrancis/gtfve |
77e778c0da65119abcb70978a313af2540e194f0 | src/clj/subman/views.clj | src/clj/subman/views.clj | (ns subman.views
(:use [hiccup core page]))
(defn index-page []
(html5 {:ng-app "subman"}
[:head
[:title "Subman - subtitle search service with api"]
(include-css "/components/bootstrap/dist/css/bootstrap.css"
"/components/bootstrap/dist/css/bootstrap-theme.css"
... | (ns subman.views
(:use [hiccup core page]))
(defn index-page []
(html5 {:ng-app "subman"}
[:head
[:title "Subman - subtitle search service with api"]
(include-css "/components/bootstrap/dist/css/bootstrap.min.css"
"/components/bootstrap/dist/css/bootstrap-theme.m... | Use minifed version of styles | Use minifed version of styles
| Clojure | epl-1.0 | submanio/subman-parser |
df8c2b59982057637f304e22807c434fecd02961 | project.clj | project.clj | (defproject io.aviso/tracker "0.1.2"
:description "Track per-thread operations when exceptions occur"
:url "https://github.com/AvisoNovate/tracker"
:license {:name "Apache Sofware Licencse 2.0"
:url "http://www.apache.org/licenses/LICENSE-2.0.html"}
:dependencies [[org.clojure/clojure "1.6.0"]
... | (defproject io.aviso/tracker "0.1.2"
:description "Track per-thread operations when exceptions occur"
:url "https://github.com/AvisoNovate/tracker"
:license {:name "Apache Sofware Licencse 2.0"
:url "http://www.apache.org/licenses/LICENSE-2.0.html"}
:dependencies [[org.clojure/clojure "1.6.0"]
... | Enable Markdown syntax in docstrings | Enable Markdown syntax in docstrings
| Clojure | apache-2.0 | AvisoNovate/tracker |
ed87ccf2d5a77a8d8459d8df87cb8f187626cbaa | project.clj | project.clj | (defproject io.aviso/tracker "0.1.3"
:description "Track per-thread operations when exceptions occur"
:url "https://github.com/AvisoNovate/tracker"
:license {:name "Apache Sofware Licencse 2.0"
:url "http://www.apache.org/licenses/LICENSE-2.0.html"}
... | (defproject io.aviso/tracker "0.1.3"
:description "Track per-thread operations when exceptions occur"
:url "https://github.com/AvisoNovate/tracker"
:license {:name "Apache Sofware Licencse 2.0"
:url "http://www.apache.org/licenses/LICENSE-2.0.html"}
... | Fix hang when deploying documentation | Fix hang when deploying documentation | Clojure | apache-2.0 | AvisoNovate/tracker |
de9b97f79e8cd6d5cc053e94cf97e094e0089205 | project.clj | project.clj | (defproject mars-ogler "0.0.1-SNAPSHOT"
:description "Holy cow, it's Mars!"
:url "http://github.com/aperiodic/mars-ogler"
:license {:name "GNU Affero GPL"
:url "http://www.gnu.org/licenses/agpl"}
:dependencies [[org.clojure/clojure "1.4.0"]
[clj-time "0.4.4"]
[compo... | (defproject mars-ogler "0.0.1-SNAPSHOT"
:description "Holy cow, it's Mars!"
:url "http://github.com/aperiodic/mars-ogler"
:license {:name "GNU Affero GPL"
:url "http://www.gnu.org/licenses/agpl"}
:dependencies [[org.clojure/clojure "1.4.0"]
[clj-time "0.4.4"]
[compo... | Update handler, add init for lein-ring | Update handler, add init for lein-ring
| Clojure | agpl-3.0 | aperiodic/mars-ogler |
cd00aaa73d0966a540b7434dc51ddf42fc1f4b11 | project.clj | project.clj | (defproject ahc-clj "0.2.0-SNAPSHOT"
:description "Async Http Client for Clojure"
:namespaces [async.http.client]
:dependencies [[org.clojure/clojure "1.2.0-beta1"]
[org.clojure/clojure-contrib "1.2.0-beta1"]
[com.ning/async-http-client "1.0.1-SNAPSHOT"]]
:dev-dependencies [[swank-c... | (defproject ahc-clj "0.2.0-SNAPSHOT"
:description "Async Http Client for Clojure"
:namespaces [async.http.client]
:dependencies [[org.clojure/clojure "1.2.0-RC2"]
[org.clojure/clojure-contrib "1.2.0-RC2"]
[com.ning/async-http-client "1.0.1-SNAPSHOT"]]
:dev-dependencies [[swank-cloju... | Upgrade Clojure to 1.2-RC2 and made swank work. | Upgrade Clojure to 1.2-RC2 and made swank work. | Clojure | apache-2.0 | bpoweski/http.async.client,michaelneale/http.async.client,xeqi/http.async.client,diamondap/http.async.client,jkk/http.async.client,adamwynne/http.async.client,vgeshel/http.async.client,josephwilk/http.async.client,oliyh/http.async.client,klang/http.async.client,canassa/http.async.client |
73819f776d6048047c7fc7fdf986414cc03626a7 | project.clj | project.clj | (defproject fault "0.1.0-SNAPSHOT"
:description "FIXME: write description"
:url "http://example.com/FIXME"
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:profiles {:dev {:dependencies [[junit/junit "4.11"]]}}
:javac-target "1.7"
:dependencies [[org.cl... | (defproject fault "0.1.0-SNAPSHOT"
:description "FIXME: write description"
:url "http://example.com/FIXME"
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:profiles {:dev {:dependencies [[junit/junit "4.11"]
[org.mockito/mo... | Make all the junit stuff a dev dependency only | Make all the junit stuff a dev dependency only
| Clojure | apache-2.0 | tbrooks8/Beehive |
f25263a21016721621f23d8b3b8dc7333b7802e8 | project.clj | project.clj | (defproject statuses "0.1.0-SNAPSHOT"
:description "Statuses app for innoQ"
:namespaces [statuses]
:dependencies [
[org.clojure/clojure "1.6.0"]
[compojure "1.2.1"]
[clj-time "0.8.0"]
[ring "1.3.1"]
[org.clojure/data.json "0.2.5"... | (defproject statuses "0.1.0-SNAPSHOT"
:description "Statuses app for innoQ"
:namespaces [statuses]
:dependencies [
[org.clojure/clojure "1.6.0"]
[compojure "1.2.1"]
[clj-time "0.8.0"]
[ring "1.3.1"]
[org.clojure/data.json "0.2.5"... | Add linting plugin to leiningen. | Add linting plugin to leiningen.
Relates to #111.
| Clojure | apache-2.0 | innoq/statuses,mvitz/statuses |
235934dc3b7339b5beb010d37eca2ea6fcc1eb38 | src/riemann/campfire.clj | src/riemann/campfire.clj | (ns riemann.campfire
"Forwards events to Campfire"
(:use [clojure.string :only [join]])
(:require [clj-campfire.core :as cf]))
(defn cf-settings
"Setup settings for campfire. Required information is your api-token, ssl connection
true or false, and your campfire sub-domain."
[token ssl sub-domain]
{:api-... | (ns riemann.campfire
"Forwards events to Campfire"
(:use [clojure.string :only [join upper-case]])
(:require [clj-campfire.core :as cf]))
(defn cf-settings
"Setup settings for campfire. Required information is your api-token, ssl connection
true or false, and your campfire sub-domain."
[token ssl sub-domai... | Improve message formatting and fn descriptions | Improve message formatting and fn descriptions
| Clojure | epl-1.0 | eric/riemann,bg451/riemann,counsyl/riemann,patrox/riemann,irudyak/riemann,pradeepchhetri/riemann,rekhajoshm/riemann,forter/riemann,cswaroop/riemann,topecz/riemann,nelhage/riemann,topecz/riemann,VideoAmp/riemann-1,pyr/riemann,vincentbernat/riemann,VideoAmp/riemann-1,counsyl/riemann,pradeepchhetri/riemann,ClodoCorp/riema... |
d901b259e9803bdbc6e9bcf5b4fcf29ef6cce409 | src/sumptus/web.clj | src/sumptus/web.clj | (ns sumptus.web
(:require [compojure.core :refer [defroutes GET]]
[ring.adapter.jetty :as ring])
(:gen-class))
(defroutes routes
(GET "/" [] "<h1>Sumptus</h1>")
(GET "/ping" []
{:status 200
:headers {"Content-Type" "text/plain"}
:body "pong"}))
(defn -main []
(ring/run-jetty #'rout... | (ns sumptus.web
(:require [compojure.core :refer [defroutes GET]]
[ring.adapter.jetty :as ring])
(:gen-class))
(defroutes routes
(GET "/" [] "<h1>Sumptus</h1>")
(GET "/ping" []
{:status 200
:headers {"Content-Type" "text/plain"}
:body "pong"}))
(defn start [port]
(ring/run-jetty #'... | Use port from the environment variable PORT. | Use port from the environment variable PORT.
| Clojure | epl-1.0 | ggiraldez/sumptus |
1a1153a294ff176ff6a801c0636ee7dda27b882b | ring-jetty-adapter/project.clj | ring-jetty-adapter/project.clj | (defproject ring/ring-jetty-adapter "1.6.0-beta1"
:description "Ring Jetty adapter."
:url "https://github.com/ring-clojure/ring"
:scm {:dir ".."}
:license {:name "The MIT License"
:url "http://opensource.org/licenses/MIT"}
:dependencies [[org.clojure/clojure "1.5.1"]
[ring/ring-co... | (defproject ring/ring-jetty-adapter "1.6.0-beta1"
:description "Ring Jetty adapter."
:url "https://github.com/ring-clojure/ring"
:scm {:dir ".."}
:license {:name "The MIT License"
:url "http://opensource.org/licenses/MIT"}
:dependencies [[org.clojure/clojure "1.5.1"]
[ring/ring-co... | Revert Jetty back to version 9.2.17 | Revert Jetty back to version 9.2.17
Jetty 9.3 requires Java 8.
| Clojure | mit | ring-clojure/ring,ring-clojure/ring |
01a0c178226dc8bfaf9596a703a81038d72241ef | test/blocks/store/buffer_test.clj | test/blocks/store/buffer_test.clj | (ns blocks.store.buffer-test
(:require
[blocks.core :as block]
(blocks.store
[memory :refer [memory-block-store]]
[buffer :refer [buffer-block-store]]
[tests :as tests])
[clojure.test :refer :all]))
(deftest buffer-behavior
(let [backer (memory-block-store)
store (buffer-bloc... | (ns blocks.store.buffer-test
(:require
[blocks.core :as block]
(blocks.store
[memory :refer [memory-block-store]]
[buffer :refer [buffer-block-store]]
[tests :as tests])
[clojure.test :refer :all]))
(deftest buffer-behavior
(let [backer (memory-block-store)
store (buffer-bloc... | Fix error in buffer block store test. | Fix error in buffer block store test.
| Clojure | unlicense | greglook/blocks,greglook/blobble,greglook/blobble |
6685e837b4490fe2f4a6041451f2e00269aa94ce | src/clj/comic_reader/sites.clj | src/clj/comic_reader/sites.clj | (ns comic-reader.sites
(:refer-clojure :exclude [list])
(:require [clojure.string :as s]))
(def list
[(let [canonical-url "http://mangafox.me"
manga-url (format "%s/manga/" canonical-url)
manga-pattern (re-pattern (str manga-url "(.*?)/"))]
{:id :manga-fox
:name "Manga Fox"
:ur... | (ns comic-reader.sites
(:refer-clojure :exclude [list])
(:require [clojure.string :as s]))
(def list
[(let [canonical-url "http://mangafox.me"
manga-url (format "%s/manga/" canonical-url)
manga-pattern (re-pattern (str manga-url "(.*?)/"))]
{:id :manga-fox
:name "Manga Fox"
:ur... | Add a fn for getting the chapter-list data for a site | Add a fn for getting the chapter-list data for a site
This makes it so that there is a uniform interface for extracting a list
of html entities from a site.
| Clojure | epl-1.0 | RadicalZephyr/comic-reader,RadicalZephyr/comic-reader |
b54c7e1b49d027c08a54b957084a95b47fec3409 | frontend/src/uxbox/config.cljs | frontend/src/uxbox/config.cljs | ;; This Source Code Form is subject to the terms of the Mozilla Public
;; License, v. 2.0. If a copy of the MPL was not distributed with this
;; file, You can obtain one at http://mozilla.org/MPL/2.0/.
;;
;; Copyright (c) 2016 Andrey Antukh <niwi@niwi.nz>
(ns uxbox.config)
(goog-define url "http://127.0.0.1:6060/api"... | ;; This Source Code Form is subject to the terms of the Mozilla Public
;; License, v. 2.0. If a copy of the MPL was not distributed with this
;; file, You can obtain one at http://mozilla.org/MPL/2.0/.
;;
;; Copyright (c) 2016 Andrey Antukh <niwi@niwi.nz>
(ns uxbox.config)
(goog-define url "http://127.0.0.1:6060/api"... | Use relative path for default Viewer URL | :art: Use relative path for default Viewer URL
| Clojure | mpl-2.0 | uxbox/uxbox,uxbox/uxbox,uxbox/uxbox |
b1844179bd78f4602f48e785e79d0e4229611ed0 | test/onyx/messaging/dummy_messenger.clj | test/onyx/messaging/dummy_messenger.clj | (ns onyx.messaging.dummy-messenger
(:require [onyx.extensions :as extensions]))
(defmethod extensions/assign-site-resources :dummy-messenger
[config peer-site peer-sites]
{:port 1})
(defrecord DummyMessenger [peer-opts])
(defn dummy-messenger [peer-opts]
(->DummyMessenger peer-opts))
(defmethod extensions/p... | (ns onyx.messaging.dummy-messenger
(:require [onyx.extensions :as extensions]))
(defmethod extensions/assign-site-resources :dummy-messenger
[config peer-site peer-sites]
{:port 1})
(defmethod extensions/get-peer-site :dummy-messenger
[replica peer]
"localhost")
(defrecord DummyMessenger [peer-opts])
(def... | Add get-peer-site for dummy messenger. | Add get-peer-site for dummy messenger.
| Clojure | epl-1.0 | dignati/onyx,iperdomo/onyx,Deraen/onyx,onyx-platform/onyx,tomasu82/onyx,intfrr/onyx,mccraigmccraig/onyx,vijaykiran/onyx,KevinGreene/onyx,ideal-knee/onyx |
c9acf8997c36bfa271891c5790b4999508dc7fee | test/multihash/test_runner.cljs | test/multihash/test_runner.cljs | (ns multihash.test-runner
(:require-macros
[doo.runner :refer [doo-tests]])
(:require
doo.runner
multihash.core-test
multihash.digest-test))
(doo-tests
'multihash.core-test
'multihash.digest-test)
| (ns multihash.test-runner
(:require-macros
[doo.runner :refer [doo-tests]])
(:require
doo.runner
multihash.core-test
#_ multihash.digest-test))
(doo-tests
'multihash.core-test
#_ 'multihash.digest-test)
| Comment out digest-test in cljs until support is added. | Comment out digest-test in cljs until support is added.
| Clojure | unlicense | greglook/clj-multihash |
90a68dff99a51500fd0e73f66a3e76347aab49a8 | immutant/project.clj | immutant/project.clj | ;; Copyright 2014 Red Hat, Inc, and individual contributors.
;;
;; Licensed under the Apache License, Version 2.0 (the "License");
;; you may not use this file except in compliance with the License.
;; You may obtain a copy of the License at
;;
;; http://www.apache.org/licenses/LICENSE-2.0
;;
;; Unless required by appl... | ;; Copyright 2014 Red Hat, Inc, and individual contributors.
;;
;; Licensed under the Apache License, Version 2.0 (the "License");
;; you may not use this file except in compliance with the License.
;; You may obtain a copy of the License at
;;
;; http://www.apache.org/licenses/LICENSE-2.0
;;
;; Unless required by appl... | Include (currently empty) caching lib in catch-all. | Include (currently empty) caching lib in catch-all.
| Clojure | apache-2.0 | kbaribeau/immutant,coopsource/immutant,coopsource/immutant,kbaribeau/immutant,immutant/immutant,kbaribeau/immutant,immutant/immutant,immutant/immutant,immutant/immutant,coopsource/immutant |
7a5213a1220c2fac516e04c20f4806cadac92907 | clojure/profiles.clj | clojure/profiles.clj | {:user
{:plugins [[lein-localrepo "0.5.4"] ;; https://github.com/kumarshantanu/lein-localrepo
[lein-nevam "0.1.2"] ;; Convert pom.xml to project.clj
[lein-pprint "1.2.0"]] ;; Pretty-print a representation of the project map
:dependencies [[alembic "0.3.2"]
[pjstadi... | {:user
{:plugins [[lein-localrepo "0.5.4"] ;; https://github.com/kumarshantanu/lein-localrepo
[lein-nevam "0.1.2"] ;; Convert pom.xml to project.clj
[lein-pprint "1.2.0"] ;; Pretty-print a representation of the project map
[nrepl "0.6.0"]]
:dependencies [[alembic "0.3.2"]
... | Add latest version of nrepl for Clojure dev | Add latest version of nrepl for Clojure dev
- cider-jack-in and rock the world
| Clojure | mit | agilecreativity/dotfiles,agilecreativity/dotfiles,agilecreativity/dotfiles |
5597810624d6a7531f882124ebb73ce6bde9f670 | ClojureScript/replete/project.clj | ClojureScript/replete/project.clj | (defproject replete "0.1.0"
:dependencies [[org.clojure/clojure "1.7.0-RC2"]
[org.clojure/clojurescript "0.0-3411"]
[org.clojure/tools.reader "0.10.0-SNAPSHOT" :exclusions [org.clojure/clojure]]])
| (defproject replete "0.1.0"
:dependencies [[org.clojure/clojure "1.7.0-RC2"]
[org.clojure/clojurescript "0.0-3422"]
[org.clojure/tools.reader "0.10.0-SNAPSHOT" :exclusions [org.clojure/clojure]]])
| Update to latest ClojureScript master | Update to latest ClojureScript master
| Clojure | epl-1.0 | mfikes/replete,mfikes/replete,mfikes/replete,bsvingen/replete,carabina/replete,mfikes/replete,mfikes/replete,asheldo/replete,karlmikko/replete,carabina/replete,asheldo/replete,hsjunnesson/replete,asheldo/replete,carabina/replete,karlmikko/replete,karlmikko/replete,hsjunnesson/replete,asheldo/replete,O-I/replete,hsjunne... |
f245656c0cde9cf88f4b7217dec3dce6dce647a7 | backend/src/uxbox/main.clj | backend/src/uxbox/main.clj | ;; This Source Code Form is subject to the terms of the Mozilla Public
;; License, v. 2.0. If a copy of the MPL was not distributed with this
;; file, You can obtain one at http://mozilla.org/MPL/2.0/.
;;
;; This Source Code Form is "Incompatible With Secondary Licenses", as
;; defined by the Mozilla Public License, v.... | ;; This Source Code Form is subject to the terms of the Mozilla Public
;; License, v. 2.0. If a copy of the MPL was not distributed with this
;; file, You can obtain one at http://mozilla.org/MPL/2.0/.
;;
;; This Source Code Form is "Incompatible With Secondary Licenses", as
;; defined by the Mozilla Public License, v.... | Add a proper way to enable/disable assertions on clojure code. | :sparkles: Add a proper way to enable/disable assertions on clojure code.
| Clojure | mpl-2.0 | uxbox/uxbox,uxbox/uxbox,uxbox/uxbox |
358822b6183d49850f0894df07c939d651b8f7a7 | clojure/koans/src/koans/11_sequence_comprehensions.clj | clojure/koans/src/koans/11_sequence_comprehensions.clj | (meditations
"Sequence comprehensions can bind each element in turn to a symbol"
(= __
(for [index (range 6)]
index))
"They can easily emulate mapping"
(= '(0 1 4 9 16 25)
(map (fn [index] (* index index))
(range 6))
(for [index (range 6)]
__))
"And also filtering"
(... | (meditations
"Sequence comprehensions can bind each element in turn to a symbol"
(= '(0 1 2 3 4 5)
(for [index (range 6)]
index))
"They can easily emulate mapping"
(= '(0 1 4 9 16 25)
(map (fn [index] (* index index))
(range 6))
(for [index (range 6)]
(* index index)))
... | Complete sequence comprenhensions koans test | Complete sequence comprenhensions koans test
| Clojure | mit | darkrodry/3languages2months,darkrodry/3languages2months,darkrodry/3languages2months,darkrodry/3languages2months |
3b250275d96a5fe8749702c7cff1d27d93a9d190 | test/zg/middleware_test.clj | test/zg/middleware_test.clj | ;
; (C) Copyright 2016 Pavel Tisnovsky
;
; All rights reserved. This program and the accompanying materials
; are made available under the terms of the Eclipse Public License v1.0
; which accompanies this distribution, and is available at
; http://www.eclipse.org/legal/epl-v10.html
;
; Contributors:
; Pavel... | ;
; (C) Copyright 2016 Pavel Tisnovsky
;
; All rights reserved. This program and the accompanying materials
; are made available under the terms of the Eclipse Public License v1.0
; which accompanies this distribution, and is available at
; http://www.eclipse.org/legal/epl-v10.html
;
; Contributors:
; Pavel... | Test for middleware module: inject-configuration | Test for middleware module: inject-configuration
| Clojure | epl-1.0 | tisnik/zg,tisnik/zg |
331fd7f5b5536a8250ba65ebad6d85ad25d56053 | src/karmanaut/crawler.clj | src/karmanaut/crawler.clj | (ns karmanaut.crawler
(:require [karmanaut.client :as client]
[karmanaut.db :as db]
[karmanaut.utils :as utils]
[monger.collection :as mc]))
(defn create-user-map [username]
; We're actually making two calls to the Reddit API
; here -- should find a way to save the data from o... | (ns karmanaut.crawler
(:require [karmanaut.client :as client]
[karmanaut.db :as db]
[karmanaut.utils :as utils]
[monger.collection :as mc]))
(defn create-user-map [username]
; We're actually making two calls to the Reddit API
; here -- should find a way to save the data from o... | Use doseq instead of dorun | Use doseq instead of dorun
doseq is like for, but specifically for performing side effects.
| Clojure | bsd-3-clause | mdippery/karmanaut |
f6fd0465cbabb5327ea8403258fbf3e7c748fdf6 | src/bytebuf/core.clj | src/bytebuf/core.clj | (ns bytebuf.core
(:refer-clojure :exclude [read])
(:require [bytebuf.spec :as spec]
[bytebuf.buffer :as buffer]
[bytebuf.proto :as proto]
[potemkin.namespaces :refer [import-vars]]))
(import-vars
[bytebuf.spec
compose-type
spec
string
string*
int32
int64]
[bytebuf.... | (ns bytebuf.core
(:refer-clojure :exclude [read byte float double short long])
(:require [bytebuf.spec :as spec]
[bytebuf.buffer :as buffer]
[bytebuf.proto :as proto]
[potemkin.namespaces :refer [import-vars]]))
(import-vars
[bytebuf.spec
compose-type
spec
string
string... | Update public api with new typespecs. | Update public api with new typespecs.
| Clojure | bsd-2-clause | funcool/octet,mbjarland/octet,funcool/octet,mbjarland/octet |
09a8de0bb5a8f96bc225f991bf01995011806e8a | src/posthere/app.clj | src/posthere/app.clj | (ns posthere.app
"PostHere.io web application."
(:gen-class)
(:require [ring.middleware.reload :as reload]
[compojure.core :refer :all]
[compojure.route :as route]
[org.httpkit.server :refer (run-server)]
[environ.core :refer (env)]
[posthere... | (ns posthere.app
"PostHere.io web application."
(:gen-class)
(:require [ring.middleware.reload :as reload]
[compojure.core :refer :all]
[compojure.route :as route]
[org.httpkit.server :refer (run-server)]
[environ.core :refer (env)]
[posthere... | Allow the home page to be served up by http-kit in development. | Allow the home page to be served up by http-kit in development.
| Clojure | mpl-2.0 | SnootyMonkey/posthere.io |
a3057d9217cb3f4b81abf180a55e83c73885a8b7 | src/regarde/db.clj | src/regarde/db.clj | (ns regarde.db
(:require [korma.db :as sql]
[ragtime.core :refer [connection migrate-all applied-migrations]]
[ragtime.sql.files]
[environ.core]))
(defn db-name [env]
(if-let [env-database (environ.core/env :database-url)]
env-database
(str "jdbc:postgresql://localhost:5... | (ns regarde.db
(:require [korma.db :as sql]
[ragtime.core :refer [connection migrate-all applied-migrations]]
[ragtime.sql.files]
[environ.core]))
;; TODO: Ragtime expects the database URL in the form jdbc:postgresql://localhost:5432/db_name?username=foo&password=bar
;; Korma expe... | Add a `TODO` describing the database URL format troubles. | Add a `TODO` describing the database URL format troubles.
| Clojure | mit | nilenso/regarde |
984af77206e755d2253f1869ea48e84dbb57276a | project.clj | project.clj | (defproject clover/lein-template "0.1.0-SNAPSHOT"
:description "A Leiningen template for an instantly deployable Reagent web app"
:url "https://github.com/listora/clover"
:license {:name "The MIT License"
:url "http://opensource.org/licenses/MIT"}
:eval-in-leiningen true
:profiles {:dev {:dependen... | (defproject clover/lein-template "0.1.0-SNAPSHOT"
:description "A Leiningen template for an instantly deployable Reagent web app"
:url "https://github.com/listora/clover"
:license {:name "The MIT License"
:url "http://opensource.org/licenses/MIT"}
:deploy-repositories [["releases" :clojars]]
:eval... | Add clojars to deploy repositories | Add clojars to deploy repositories
| Clojure | mit | jcf/clover |
2376d8e822fac69668980f96786c17c334f19384 | project.clj | project.clj | (defproject skat "0.1.0-SNAPSHOT"
:description "Skat game engine"
:url "https://bitbucket.org/MateuszKubuszok/skat"
:license { :name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html" }
:dependencies [[org.clojure/clojure "1.6.0"]
[org.clojure/core.match "0.... | (defproject skat "0.1.0-SNAPSHOT"
:description "Skat game engine"
:url "https://bitbucket.org/MateuszKubuszok/skat"
:license { :name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html" }
:dependencies [[org.clojure/clojure "1.6.0"]
[org.clojure/core.match "0.... | Build and run as UTF-8 files | Build and run as UTF-8 files
| Clojure | epl-1.0 | MateuszKubuszok/Skat |
d4b7d5fb772ddd99c25cb1441a9e580a0e5a25a1 | project.clj | project.clj | (defproject onyx-plugin/lein-template "0.8.2.3"
:description "A Leiningen 2.0 template for new Onyx plugins"
:url "http://github.com/MichaelDrogalis/onyx-plugin"
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:repositories {"snapshots" {:url "https://cloja... | (defproject onyx-plugin/lein-template "0.8.2.4-SNAPSHOT"
:description "A Leiningen 2.0 template for new Onyx plugins"
:url "http://github.com/MichaelDrogalis/onyx-plugin"
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:repositories {"snapshots" {:url "http... | Prepare for next release cycle. | Prepare for next release cycle.
| Clojure | epl-1.0 | onyx-platform/onyx-plugin |
7f5f191a2532e68bab1d6fe4fb4a041d73b83445 | src/onyx/types.clj | src/onyx/types.clj | (ns onyx.types)
(defrecord Leaf [message id acker-id completion-id ack-val ack-vals route routes hash-group])
(defn leaf
([message]
(->Leaf message nil nil nil nil nil nil nil nil)))
(defrecord Route [flow exclusions post-transformation action])
(defrecord Ack [id completion-id ack-val timestamp])
(defrec... | (ns onyx.types)
(defrecord Leaf [message id acker-id completion-id ack-val ack-vals route routes hash-group])
(defn leaf
([message]
(->Leaf message nil nil nil nil nil nil nil nil)))
(defrecord Route [flow exclusions post-transformation action])
(defrecord Ack [id completion-id ack-val timestamp])
(defrec... | Add some records for monitoring events which will improve perf | Add some records for monitoring events which
will improve perf
| Clojure | epl-1.0 | Deraen/onyx,KevinGreene/onyx,iperdomo/onyx,dignati/onyx,onyx-platform/onyx,ideal-knee/onyx,vijaykiran/onyx,mccraigmccraig/onyx |
4a35bba58917fb361fcf58725e1ece907075955b | project.clj | project.clj | (defproject caesium "0.8.0-SNAPSHOT"
:description "libsodium for clojure"
:url "https://github.com/lvh/caesium"
:deploy-repositories [["releases" :clojars]
["snapshots" :clojars]]
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:de... | (defproject caesium "0.8.0-SNAPSHOT"
:description "libsodium for clojure"
:url "https://github.com/lvh/caesium"
:deploy-repositories [["releases" :clojars]
["snapshots" :clojars]]
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:de... | Add byte-streams for type conversions | Add byte-streams for type conversions
| Clojure | epl-1.0 | lvh/caesium |
368907ade80a6e219e3091faf3b28924b849de40 | project.clj | project.clj | (defproject org.onyxplatform/onyx-datomic "0.7.0.7"
:description "Onyx plugin for Datomic"
:url "https://github.com/MichaelDrogalis/onyx-datomic"
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:dependencies [[org.clojure/clojure "1.7.0"]
[... | (defproject org.onyxplatform/onyx-datomic "0.7.0.7-SNAPSHOT"
:description "Onyx plugin for Datomic"
:url "https://github.com/MichaelDrogalis/onyx-datomic"
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:dependencies [[org.clojure/clojure "1.7.0"]
... | Drop auto-release config for now. | Drop auto-release config for now.
| Clojure | epl-1.0 | onyx-platform/onyx-datomic |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.