Skip to content

Instantly share code, notes, and snippets.

View jdg's full-sized avatar

Jonathan George jdg

View GitHub Profile
#!/usr/bin/env ruby
require 'rubygems'
require 'tweetstream'
require 'boxcar_api'
SETTINGS = {
:key => 'xyz', # Provider Key
:secret => 'xyz', # Provider Secret
:tweeter => 'macrumorslive' # Whom we'll be following on Twitter
:tweeter_id => 1581511, # The tweeter's user id (check their RSS feed)
#!/usr/bin/ruby
require 'osx/cocoa'
require 'date'
OSX.require_framework "AddressBook"
filePath = "%%%{PBXFilePath}%%%"
fileName = File.basename(filePath)
projName = File.basename(File.dirname(filePath))
# Author: Pieter Noordhuis
# Description: Simple demo to showcase Redis PubSub with EventMachine
#
# Requirements:
# - rubygems: eventmachine, thin, cramp, sinatra, yajl-ruby
# - a browser with WebSocket support
#
# Usage:
# ruby redis_pubsub_demo.rb
#
# define ALog(fmt, ...) NSLog((@"%s [Line %d] " fmt), __PRETTY_FUNCTION__, __LINE__, ##__VA_ARGS__);
# ifdef DEBUG
# define DLog(fmt, ...) ALog(fmt, ##__VA_ARGS__);
# else
# define DLog(...)
# endif
/*
* Memory.c
* Outpost
*
* Created by Jim Dovey on 23/04/09.
* Copyright 2009 Morfunk, LLC. All rights reserved.
*
* Copyright (c) 2009, Jim Dovey
* All rights reserved.
*