Skip to content

Instantly share code, notes, and snippets.


Aaron Cruz mraaroncruz

View GitHub Profile
mraaroncruz / spam.txt
Last active August 29, 2015 13:57
more awesome SPAM
View spam.txt
I am Mr. Howard Wilson, Director Unit United Nations Inspection Agent in Hartsfield International Airport Atlanta Georgia USA .
During our investigation,I discovered An abandoned shipment through a Diplomat from United Kingdom via Africa under iship
forwarder which was transferred from JF Kennedy Airport to our facility here in Atlanta. When scanned, it revealed an undisclosed
sum of money in a Metal Trunk Box weighing approximately 55kg each. The consignment was abandoned because the Content was not
properly declared by the consignee as (money) rather it was declared as personal effect to avoid diversion by the Shipping Agent
also the Diplomat inability to pay for Non Inspection Fees.
mraaroncruz / console.rb
Last active August 29, 2015 13:57
mlted client repl with setup
View console.rb
#!/usr/bin/env ruby
require 'bundler/setup'
Bundler.require(:default, (ENV['RACK_ENV'] || :development))
require File.expand_path("../../lib/mlted_service_client", __FILE__)
require 'pry'
SERVER = "http://localhost:9090"
block =
mraaroncruz / console.rb
Created March 8, 2014 13:46
melted client repl setup
View console.rb
#!/usr/bin/env ruby
require 'pathname'
ENV['BUNDLE_GEMFILE'] ||= File.expand_path("../../Gemfile",
require 'rubygems'
require 'bundler/setup'
require 'melted_client'
mraaroncruz / gist
Created March 10, 2014 15:06
Beginning of SOLID refactoring talk
View gist
#!/usr/bin/env ruby
require 'uri'
require 'net/http'
require 'json'
USER = "pferdefleisch"
def get_gists current_page
uri = URI("{USER}/gists?page=#{current_page}")
res = Net::HTTP.get_response(uri)
mraaroncruz /
Created March 22, 2014 14:09
vagrant talk discussion

Discussion below in comments

mraaroncruz / z-index.sass
Created May 1, 2014 10:00
z-indeces that make more sense
View z-index.sass
z-index: 20000
@extend .highest-z
z-index: 15000
@extend .high-middle-z
z-index: 10000
mraaroncruz /
Last active August 29, 2015 14:01
How to use mlt framework with ruby

So there are 3 possibilities that I see for getting mlt to work with Ruby.

  1. Run melted and build a ruby client for it. I actually partially built one that I would share with you if you are interested
  2. Use FFI and connect directly to “mlt.h.” This is the direction I would have headed in if I was still using mlt.
  3. Compile the Ruby SWIG bindings, fire up pry (pry was instrumental in being to do anything with the mlt bindings for me) and play around. If you are messing around in the repl, you can send arguments of the wrong type to methods and the error generally tells you what kind of argument it wants. With pry you can also ls classes and objects to see the methods available on them (awesome!).

Here are the lines that expose the SWIG API to the C++ API. So the Ruby classes you can use when you require “mlt”. ex.

mraaroncruz /
Last active August 29, 2015 14:02
BBQ Rechnung

Summary - all calculations other files below

The BBQ cost 133 EUR and took in 120 EUR. We have a left over case of beer and a few bags of chips which means we pretty much broke even.

For the 4th of July BBQ, I'll offer something special for the burger purchases from the last BBQ, I don't know what yet.

What this all means is that the burger eaters bankrolled the whole thing.

I would like to charge less for the burgers. I would also like to provide beer, water and other beverages.


with 5 items

obj = {};
for (var i = 0, l = 5; i < l; i++) {
    obj["foo" + i] = "bar";