Skip to content

Instantly share code, notes, and snippets.

View mathieuravaux's full-sized avatar

Mathieu Ravaux mathieuravaux

  • Paris
View GitHub Profile
(ns ansible.core
(:require [clojure.java.shell :as sh]
[clojure.string :as str]
[cheshire.core :as cheshire]
[clojure.java.io :as io])
(:import (java.io File)
(com.fasterxml.jackson.core JsonGenerator)
(java.util Base64)
(java.security MessageDigest MessageDigest$Delegate)))
@mathieuravaux
mathieuravaux / datomic.clj
Created April 27, 2018 15:10 — forked from robert-stuttaford/datomic.clj
Handy protocols for working with Datomic
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;; Connection
(defprotocol DatomicConnection
(as-conn [_]))
(extend-protocol DatomicConnection
datomic.Connection
(as-conn [c] c)
datomic.db.Db
@mathieuravaux
mathieuravaux / keybase.md
Created January 11, 2018 10:59
keybase.md

Keybase proof

I hereby claim:

  • I am mathieuravaux on github.
  • I am mathieuravaux (https://keybase.io/mathieuravaux) on keybase.
  • I have a public key ASDPRmALoSFdhVcLFW4l3i3pZfjZjlMaI6qj7_pGIA6JeQo

To claim this, I am signing this object:

@mathieuravaux
mathieuravaux / backend-architectures.md
Created November 26, 2015 15:38 — forked from ragingwind/Backend Architectures Keywords and References.md
Backend Architectures Keywords and References. #wiki
@mathieuravaux
mathieuravaux / README.md
Last active August 29, 2015 14:07 — forked from mbostock/.block
We couldn’t find that file to show.
@mathieuravaux
mathieuravaux / syntax.rb
Created April 17, 2012 16:15 — forked from slemiere/syntax.rb
redis queues syntax
all_queues = ["test", "schedule", "process"]
QUEUES = "*"
# ["test", "schedule", "process"]
QUEUES = "test,schedule"
# ["test", "schedule"]
QUEUES = "*,~test"
# ["schedule", "process"]
@mathieuravaux
mathieuravaux / airbrake_initializer.rb
Created April 10, 2012 19:09
Airbrake monkeypatch to serialize correctly Mongoid documents
class ::Airbrake::Notice
def xml_vars_for(builder, hash)
hash.each do |key, value|
value = value.to_airbrake if value.respond_to?(:to_airbrake)
if value.respond_to?(:to_hash)
builder.var(:key => key){|b| xml_vars_for(b, value.to_hash) }
else
builder.var(value.to_s, :key => key)
end
end
# Store data in /usr/local/var/mongodb instead of the default /data/db
dbpath = /usr/local/var/mongodb
# Only accept local connections
bind_ip = 127.0.0.1
cpu = true
verbose = true
rest = true
kern.ostype = Darwin
kern.osrelease = 11.2.0
kern.osrevision = 199506
kern.version = Darwin Kernel Version 11.2.0: Tue Aug 9 20:54:00 PDT 2011; root:xnu-1699.24.8~1/RELEASE_X86_64
kern.maxvnodes = 66560
kern.maxproc = 1064
kern.maxfiles = 12288
kern.argmax = 262144
kern.securelevel = 0
kern.hostname = Mathieus-MacBook-Air.local
kern.netboot = 0
kern.netboot: 0
net.local.stream.sendspace: 8192
net.local.stream.recvspace: 8192
net.local.stream.tracemdns: 0
net.local.dgram.maxdgram: 2048
net.local.dgram.recvspace: 4096
net.local.inflight: 0
net.inet.ip.portrange.lowfirst: 1023
net.inet.ip.portrange.lowlast: 600