Skip to content

Instantly share code, notes, and snippets.

Avatar

Brandon Fish bjfish

View GitHub Profile
@bishboria
bishboria / springer-free-maths-books.md
Last active Jul 10, 2020
Springer made a bunch of books available for free, these were the direct links
View gist:698bd36e2ddba92049fc
$ bin/jruby -X+T bin/irb
irb(main):001:0> Truffle::CExt.inline %s{
irb(main):002:0: #include <unistd.h>
irb(main):003:0: #include <stdio.h>
irb(main):004:0: }, %s{
irb(main):005:0: printf("Hello, World! I'm %d\n", getpid());
irb(main):006:0: }
Hello, World! I'm 36641
=> true
irb(main):002:0> exit
@gsoltis
gsoltis / rx.firebase.js
Last active Mar 2, 2017
Quick Firebase / RxJS binding prototype
View rx.firebase.js
(function () {
var makeCallback = function(eventType, observer) {
if (eventType === 'value') {
return function(snap) {
observer.onNext(snap);
};
} else {
return function(snap, prevName) {
// Wrap into an object, since we can only pass one argument through.
observer.onNext({snapshot: snap, prevName: prevName});
@ragnard
ragnard / redis.clj
Last active Sep 7, 2016
Using Redis for persistent memoization of Clojure functions
View redis.clj
(ns util.redis
(:refer-clojure :exclude [memoize])
(:require [taoensso.carmine :as car]))
;; boilerplate stuff that is not in Carmine
(def ^:dynamic ^:private *pool*)
(def ^:dynamic ^:private *spec*)
(defmacro with-redis
@carlo-rtr
carlo-rtr / DropwizardDAOTest
Created Nov 15, 2012
DAO Testing with Dropwizard hibernate
View DropwizardDAOTest
package com.rtr.infra.wizard.test;
import org.hibernate.Session;
import org.hibernate.SessionFactory;
import org.hibernate.context.internal.ManagedSessionContext;
import org.junit.After;
import org.junit.Before;
public abstract class DropwizardDAOTest {
You can’t perform that action at this time.