Skip to content

Instantly share code, notes, and snippets.

Matthew Maravillas maravillas

Block or report user

Report or block maravillas

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View keybase.md

Keybase proof

I hereby claim:

  • I am maravillas on github.
  • I am maravillas (https://keybase.io/maravillas) on keybase.
  • I have a public key ASBYMEUIy72LgHU880uLBLoixjlCq-0rPC-Ou24QlOaxFAo

To claim this, I am signing this object:

View convex-hull.cljs
(ns giornata.core
(:require [enchilada :refer [canvas ctx value-of canvas-size]]
[jayq.core :refer [show]]
[monet.core :refer [animation-frame]]
[monet.canvas :refer [save restore
circle
begin-path move-to line-to close-path
stroke stroke-style fill fill-rect fill-style
rotate translate]]
[giornata.hull :refer [convex-hull]]
View robpike.cljs
;; based on http://talks.golang.org/2012/concurrency.slide#50
(ns robpike
(:require [cljs.core.async :as async :refer [<! >! chan close!]])
(:require-macros [cljs.core.async.macros :as m :refer [go alt!]]))
(defn timeout [ms]
(let [c (chan)]
(js/setTimeout (fn [] (close! c)) ms)
c))
View robpike.cljs
;; http://programming-enchiladas.destructuring-bind.org/swannodette/5903001
;; based on http://talks.golang.org/2012/concurrency.slide#50
(ns robpike
(:require [cljs.core.async :as async :refer [<! >! chan close!]])
(:require-macros [cljs.core.async.macros :as m :refer [go alt!]]))
(defn timeout [ms]
(let [c (chan)]
@maravillas
maravillas / interceptor.coffee
Created Oct 22, 2011
Trace method calls in console
View interceptor.coffee
interceptor = (klass) ->
for own key, value of klass
f = (k, v) ->
if typeof value == "function"
klass[k] = ->
console.log "Called #{k} from #{arguments.callee.caller.toString()}", arguments
v.apply(this, arguments)
f key, value
// interceptor(Foo.prototype)
View Driver.java
/**
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You 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
*
View gist:647028
If LEIN_JAR is not manually set by the user:
Line 3: set LEIN_VERSION
Line 5: goto SELF_INSTALL
Line 78: check %LEIN_JAR%
At this point, the script exits with this error:
The syntax of the command is incorrect.
You can’t perform that action at this time.