Skip to content

Instantly share code, notes, and snippets.

I may be slow to respond.

ars moriendi horacio

I may be slow to respond.
  • Buenos Aires, Argentina
Block or report user

Report or block horacio

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
mankind / rails-jsonb-queries
Last active Dec 6, 2019
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 Nov 29, 2019
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 Dec 5, 2019
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.

#!/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 Dec 8, 2019
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.


View gist:20037a488409dd2d7df1
module Enumerable
def each_with_emptiness
return to_enum(__callee__) unless block_given?
if empty?
yield nil, true
each do |element|
yield element, false
DateNameNetworkPlacepingdown mbpsup mbps
22/11/2013Cafe DaltonBuenos Aires183.040.51
23/11/2013Cam24Buenos Aires521.570.49
25/11/2013Alpina SkateBuenos Aires204.941.15
26/11/2013Recoletta HostelBuenos Aires160.950.25
30/11/2013Alvear HostelSSCCordoba294.043.85
02/12/2013La MoraCordoba319.781.16
08/12/2013Alvear HostelFiberte
You can’t perform that action at this time.