Skip to content

Instantly share code, notes, and snippets.

View danieltahara's full-sized avatar

Daniel Tahara danieltahara

View GitHub Profile
@jpantuso
jpantuso / osx_lion_rail_setup.md
Created July 27, 2011 19:51
Setup OS X 10.7 w/ homebrew, oh-my-zsh, rvm, rails, and MySQL
@c2nes
c2nes / dumpjson.py
Created February 23, 2012 01:05
Convert Wikipedia XML dump to JSON
#!/usr/bin/env python
import os
import sys
SOURCE_FILE = "/home/cmthunes/enwiki-20120211-pages-meta-current.xml"
OUTPUT_FILE = "/mnt/reports/cmthunes/enwiki-20120211.json"
def extract_with_delims(s, start_delim, end_delim):
start_index = s.find(start_delim)
@ZenBowman
ZenBowman / example.java
Last active April 24, 2017 07:30
Using the Hive Thrift Client in Java and Scala - an example
import junit.framework.TestCase;
import org.apache.hadoop.hive.service.HiveClient;
import org.apache.thrift.TException;
import org.apache.thrift.protocol.TBinaryProtocol;
import org.apache.thrift.protocol.TProtocol;
import org.apache.thrift.transport.TSocket;
import java.util.List;
/**