Skip to content

Instantly share code, notes, and snippets.

View craig-ludington's full-sized avatar

Craig Ludington craig-ludington

View GitHub Profile
@craig-ludington
craig-ludington / gist:2d8bf9804cbbc93731a9
Created March 31, 2015 19:20
Exception that happens on only one machine.
Retrieving clojure-complete/clojure-complete/0.2.3/clojure-complete-0.2.3.jar from clojars
#<CompilerException java.lang.IllegalArgumentException: No single method: _setup of interface: cljs.repl.IJavaScriptEnv found for function: -setup of protocol: IJavaScriptEnv, compiling:(cemerick/piggieback.clj:149:5)>
Exception in thread "main" java.lang.RuntimeException: Unable to resolve var: cemerick.piggieback/wrap-cljs-repl in this context, compiling:(/private/var/folders/j7/0jk8693s26j_jn80w_7w6sw000010j/T/form-init8804850253847573659.clj:1:2644)
at clojure.lang.Compiler.analyzeSeq(Compiler.java:6651)
at clojure.lang.Compiler.analyze(Compiler.java:6445)
at clojure.lang.Compiler.analyze(Compiler.java:6406)
at clojure.lang.Compiler$InvokeExpr.parse(Compiler.java:3719)
at clojure.lang.Compiler.analyzeSeq(Compiler.java:6646)
at clojure.lang.Compiler.analyze(Compiler.java:6445)
at clojure.lang.Compiler.analyze(Compiler.java:6406)
@craig-ludington
craig-ludington / You cannot copy text!.js
Created October 14, 2015 15:54
These data are no longer on our web site.
<script>
$(document).ready(function() {
$(function() {
$('body').bind('cut copy', function(e) {
e.preventDefault();
alert('You cannot ' + e.type + ' text!');
});
});
$(function() {
$(this).bind("contextmenu", function(e) {

Keybase proof

I hereby claim:

  • I am craig-ludington on github.
  • I am alpheus (https://keybase.io/alpheus) on keybase.
  • I have a public key whose fingerprint is EDF4 74B1 C642 BBFE E72A 0B88 00F3 4B7E 3079 CBFF

To claim this, I am signing this object:

(defn score
[word]
(let [wc (count word)
uc (count (into #{} (map identity (clojure.string/lower-case word))))]
{:word word :score (if (= wc uc) wc 0)}))
(defn winner
[words]
(let [m (group-by :score (map score words))]
(m (apply max (keys m)))))
0x7cfFeBD2600b27C31C40d16586d8229405Ff1182
0x8aBadCAe5D552d0204b036fc32f9321DA31159FE
0x574372F9258c71C6c5E3Acb2F9EF54C632e376D7
0x07005ed8d67bbf9291ffa957d2362d6f3d936914