Skip to content

Instantly share code, notes, and snippets.

View jazzido's full-sized avatar
💭
𝄢

Manuel Aristarán jazzido

💭
𝄢
View GitHub Profile
@jazzido
jazzido / README.md
Last active August 29, 2015 14:27
Mesas en las que un único partido obtuvo votos

La consulta SQL que se muestra se puede ejecutar en la versión SQLite de la base Access que publica la Dirección Nacional Electoral. La consulta incluye todas las mesas, inclusive aquellas que puedan tener incidencias.

Aclaración anti-boludos: si van a hacer escándalo, asegúrense de no estar diciendo cualquier cosa. Chequeen contra los telegramas publicados en resultados.gob.ar

Feature: Cross-compile C extensions
In order to avoid bitching from Windows users
As a Ruby developer on Linux
I want some rake tasks that take away the pain of compilation
Scenario: compile single extension
Given that all my source files are in place
And I'm running a POSIX operating system
And I've installed cross compile tools
@jazzido
jazzido / energy.json
Last active August 30, 2015 06:59 — forked from billierinaldi/energy.json
Overlapping Sankey links
{"nodes":[
{"name":"Agricultural 'waste'"},
{"name":"Bio-conversion"},
{"name":"Liquid"},
{"name":"Losses"},
{"name":"Solid"},
{"name":"Gas"},
{"name":"Biofuel imports"},
{"name":"Biomass imports"},
{"name":"Coal imports"},
@jazzido
jazzido / gist:154720
Created July 25, 2009 06:42
Rapidshare Reminder -- Session expirations, no more!
var notif = jetpack.notifications.show;
var statusWidget = null;
var widget = {
html: '<span></span>',
width: 20,
onReady: function(w) {
statusWidget = $(w);
statusWidget.span = statusWidget.find('span');
}
<!--- original from ffffound --->
<item>
<title>Exhibitions</title>
<link>http://ffffound.com/image/2f6feffab512ca2e8d5b791a530323c02eba0404</link>
<description>&lt;p&gt;&lt;a href="http://ffffound.com/image/2f6feffab512ca2e8d5b791a530323c02eba0404"&gt;&lt;img src="http://img.ffffound.com/static-data/assets/6/2f6feffab512ca2e8d5b791a530323c02eba0404_m.jpg" alt="" border="0" width="480" height="451"&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;via &lt;a href="http://www.artmap.com.tw/2-show-past/02-show9809-eng.htm"&gt;http://www.artmap.com.tw/2-show-past/02-show9809-eng.htm&lt;/a&gt;&lt;/p&gt;</description>
<guid isPermaLink="true">http://ffffound.com/image/2f6feffab512ca2e8d5b791a530323c02eba0404</guid>
<author>pjbond</author>
<pubDate>Sat, 20 Mar 2010 17:04:22 +0900</pubDate>
<media:content url="http://img.ffffound.com/static-data/assets/6/2f6feffab512ca2e8d5b791a530323c02eba0404_m.jpg" />
{"version": "1.1.0",
"request_address": true,
"wifi_towers": [{"mac_address": "00-23-cd-d6-df-02", "ssid": "inkpro.net", "signal_strenght": -65 },
{"mac_address": "00-40-0c-04-05-93", "ssid": "inkpro.net", "signal_strenght": -90 }]
# coding: utf-8
from datetime import datetime, timedelta
class GPolyline(object):
def __init__(self, points, foo1, foo2):
self.points = points
class GLatLng(object):
def __init__(self, lat, lng):
==> Caveats
To build plpython against a specific Python, set PYTHON prior to brewing:
PYTHON=/usr/local/bin/python brew install postgresql
See:
http://www.postgresql.org/docs/9.0/static/install-procedure.html
If this is your first install, create a database with:
initdb /usr/local/homebrew/var/postgres
# no me digan nada, es horrible.
import csv
import json
rows = list(csv.reader(open('votos2010.csv').readlines(), delimiter=";"))[1:]
diputados = map(lambda x: x[0], rows)
partidos = list(set(map(lambda x: x[1], rows)))
@jazzido
jazzido / gist:1133176
Created August 9, 2011 00:53
Convertir escrutinios electorales elección Gobernador pcia Córdoba 2011
# convertir escrutinios de eleccion gobernador 2011 pcia de Cordoba a un CSV
# Script horrible.
# requiere la presencia de algunos archivos en el directorio en donde se ejecuta
# para obtenerlos:
#
# $ wget http://www.eleccordoba2011.com.ar/iniele/listas.xml
# $ wget http://www.eleccordoba2011.com.ar/iniele/secciones.xml
# $ for i in `seq 1 26`; do wget http://www.eleccordoba2011.com.ar/resultados/Seccion_`printf %02d $i`_Municipio_000_Circuito_000_Cargo_01.xml; done
#
# Copyright (c) <2011> <Manuel Aristaran - http://jazzido.com>