Skip to content

Instantly share code, notes, and snippets.

View alfredormz's full-sized avatar
:octocat:

Alfredo Ramírez alfredormz

:octocat:
View GitHub Profile
@jazzido
jazzido / PASO 2017 - Centros de votación geolocalizados.ipynb
Last active August 16, 2019 16:47
PASO 2017 — Intentando Geolocalizar los establecimientos de votación
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@pedro
pedro / jack-white-guac.md
Last active August 29, 2015 14:14
Jack White's guacamole recipe

Jack White's guacamole recipe

Recently the tour rider for a Jack White performance was made public, and it contained a recipe for guacamole intended to be made for the artist.

Ingredients

  • 8x large ripe Haas avocados
  • 4x vine-ripened tomatoes (diced)
  • ½ yellow onion finely chopped
  • 4x Serrano pepper (de-veined and chopped)
git checkout master
git gc
git remote | while read remote; do
git remote prune $remote
done
git branch --merged | grep -v "\*" | xargs -n 1 git branch -d
@lelandbatey
lelandbatey / whiteboardCleaner.md
Last active April 25, 2024 02:01
Whiteboard Picture Cleaner - Shell one-liner/script to clean up and beautify photos of whiteboards!

Description

This simple script will take a picture of a whiteboard and use parts of the ImageMagick library with sane defaults to clean it up tremendously.

The script is here:

#!/bin/bash
convert "$1" -morphology Convolve DoG:15,100,0 -negate -normalize -blur 0x1 -channel RBG -level 60%,91%,0.1 "$2"

Results

@aras-p
aras-p / preprocessor_fun.h
Last active May 23, 2024 08:26
Things to commit just before leaving your job
// Just before switching jobs:
// Add one of these.
// Preferably into the same commit where you do a large merge.
//
// This started as a tweet with a joke of "C++ pro-tip: #define private public",
// and then it quickly escalated into more and more evil suggestions.
// I've tried to capture interesting suggestions here.
//
// Contributors: @r2d2rigo, @joeldevahl, @msinilo, @_Humus_,
// @YuriyODonnell, @rygorous, @cmuratori, @mike_acton, @grumpygiant,
@jamesmoriarty
jamesmoriarty / deploy.rb
Created December 14, 2012 03:38
Sidekiq, Upstart, and Capistrano
namespace :deploy do
namespace :sidekiq do
desc 'Replace upstart config for sidekiq-workers'
task :upstart_config do
data = %Q{
start on runlevel [2345]
stop on runlevel [!2345]
respawn
exec su - #{user} -c 'cd #{release_path}; export RAILS_ENV=#{stage}; bundle exec sidekiq -q default,1 -c 4 -pid #{release_path}/tmp/pids/sidekiq.pid >> #{release_path}/log/sidekiq.log 2>&1'
@fairchild
fairchild / Gemfile
Created December 7, 2011 09:58
An example sinatra omniauth client app
source :rubygems
gem 'sinatra'
gem 'json'
gem 'omniauth'
gem 'omniauth-oauth2'
gem 'omniauth-github'
# gem 'omniauth-att', :path => File.expand_path("./../../omniauth-att", __FILE__)
gem 'thin'