Skip to content

Instantly share code, notes, and snippets.

Working from home

ars moriendi horacio

Working from home
View GitHub Profile
View history.txt
I was drawn to programming, science, technology and science fiction
ever since I was a little kid. I can't say it's because I wanted to
make the world a better place. Not really. I was simply drawn to it
because I was drawn to it. Writing programs was fun. Figuring out how
nature works was fascinating. Science fiction felt like a grand
Then I started a software company and poured every ounce of energy
into it. It failed. That hurt, but that part is ok. I made a lot of
mistakes and learned from them. This experience made me much, much
mankind / rails-jsonb-queries
Last active Oct 20, 2020
Rails-5 postgresql-9.6 jsonb queries
View rails-jsonb-queries
#payload: [{"kind"=>"person"}]
Segment.where("payload @> ?", [{kind: "person"}].to_json)
#data: {"interest"=>["music", "movies", "programming"]}
Segment.where("data @> ?", {"interest": ["music", "movies", "programming"]}.to_json)
Segment.where("data #>> '{interest, 1}' = 'movies' ")
Segment.where("jsonb_array_length(data->'interest') > 1")
yossorion /
Last active Oct 30, 2020
What I Wish I'd Known About Equity Before Joining A Unicorn

What I Wish I'd Known About Equity Before Joining A Unicorn

Disclaimer: This piece is written anonymously. The names of a few particular companies are mentioned, but as common examples only.

This is a short write-up on things that I wish I'd known and considered before joining a private company (aka startup, aka unicorn in some cases). I'm not trying to make the case that you should never join a private company, but the power imbalance between founder and employee is extreme, and that potential candidates would

cavi21 /
Created May 4, 2016
Generate an access token for a MercadoLibre Account without the need of doing it through OAuth flow
curl -s -X POST -H 'content-type: application/x-www-form-urlencoded' '' -d 'grant_type=client_credentials' -d 'client_id=[CLIENT_ID]' -d 'client_secret=[CLIENT_SECRET]'
benlinton /
Last active Oct 15, 2020
Multiple MySQL Versions with Homebrew

Multiple MySQL Versions for Development

Options included below:

  • Using Docker docker-compose
  • Using Homebrew brew

Using Docker (recommended)

This gist was originally created for Homebrew before the rise of Docker, yet it may be best to avoid installing mysql via brew any longer. Instead consider adding a barebones docker-compose.yml for each project and run docker-compose up to start each project's mysql service.

hfreire /
Last active Oct 28, 2020
How to emulate a Raspberry Pi (Raspbian Jessie) on Mac OSX (El Capitan)
# Install QEMU OSX port with ARM support
sudo port install qemu +target_arm
export QEMU=$(which qemu-system-arm)
# Dowload kernel and export location
curl -OL \
export RPI_KERNEL=./kernel-qemu-4.1.7-jessie
# Download filesystem and export location
#!/usr/bin/sudo sh
## -- decrypt obfuscated GHE .rb files. 2.0.0 to 2.3.1+.
## From `strings`:
## > This obfuscation is intended to discourage GitHub Enterprise customers
## > from making modifications to the VM.
## Well, good, as long as its not intended to discourage *me* from doing this!

I highly suspect that the RSpec core team all use black backgrounds in their terminals because sometimes the colors aren’t so nice on my white terminal

I certainly use a black background. I'm not sure about the other RSpec core folks. Regardless, if there are some color changes we can make that would make output look good on a larger variety of backgrounds, we'll certainly consider that (do you have some suggested changes?). In the meantime, the colors are configurable, so you can change the colors to fit your preferences on your machine. First, create a file at

pengwynn / backslash.rb
Created Jan 9, 2015
Where I prefer \ to parens in Ruby
View backslash.rb
hash.update \
:name =>,
:company =>,
:blog =>,
:location => profile.location,
:email =>,
:hireable => profile.hireable,
luislavena /
Last active Sep 28, 2020
Workaround RubyGems' SSL errors on Ruby for Windows (RubyInstaller)

SSL upgrades on and RubyInstaller versions

UPDATE 2016-12-01: Please refer to the official guide instead of this process.

UPDATE 2014-12-21: RubyGems 1.8.30, 2.0.15 and 2.2.3 have been released. It requires manual installation, please see instructions below.


You can’t perform that action at this time.