Skip to content

Instantly share code, notes, and snippets.

View jsmestad's full-sized avatar
👾

Justin Smestad jsmestad

👾
View GitHub Profile

Terms of Service

Last revised on [DATE]

The Gist

[COMPANY] operates the [SERVICE] service, which we hope you use. If you use it, please use it responsibly. If you don't, we'll have to terminate your account.

For paid accounts, you'll be charged on a monthly basis. You can cancel anytime, but there are no refunds.

var sys=require('sys'), http = require('http');
var target = "jsconf";
var connection = http.createClient(80, "search.twitter.com");
var since = 0;
function getTweets() {
var request = connection.request('GET', "/search.json?q=" + target + "&since_id="+since) //, {"host": "search.twitter.com", "User-Agent": "NodeJS HTTP Client"});
request.finish(function(response) {
var responseBody = "";
response.setBodyEncoding("utf8");
#!/bin/bash
echo "Setting up chef..."
sudo apt-get -y update
sudo apt-get -y install ruby ruby1.8-dev libopenssl-ruby1.8 rdoc ri irb build-essential wget ssl-cert
cd /tmp
wget http://rubyforge.org/frs/download.php/57643/rubygems-1.3.4.tgz
tar zxf rubygems-1.3.4.tgz
@jsmestad
jsmestad / .vimrc
Created February 24, 2010 17:24 — forked from hone/.vimrc
set nocompatible " We're running Vim, not Vi!
syntax on " Enable syntax highlighting
set nocp " for omnicppcomplete plugin
filetype on " Enable filetype detection
filetype indent on " Enable filetype-specific indenting
filetype plugin on " Enable filetype-specific plugins
set laststatus=2
set statusline=%<%f\ %h%m%r%=%-20.(%)\%h%m%r%=%-40(%n%Y%)\%P
set nocul " cursor line
set cf " Enable error files & error jumping
@jsmestad
jsmestad / Gemfile
Created February 16, 2010 22:05 — forked from d--j/Gemfile
# include at least one source and the rails gem
source :gemcutter
gem 'rails', '~> 2.3.5', :require => nil
group :development do
# bundler requires these gems in development
gem 'rails-footnotes'
end
group :test do
# Rails 2.3 metal file to incorporate Resque Web UI inside Rails application.
# Uses HTTP Basic Authentication, until I can figure out how to get Authlogic
# working here. Accepts only users listed in ADMINS.
require "resque/server"
# since Authlogic is not keeping up, see http://github.com/binarylogic/authlogic/issuesearch?state=open&q=sinatra#issue/80
class Sinatra::Request
def self.before
end
end
@jsmestad
jsmestad / gist:290735
Created January 30, 2010 21:29 — forked from rkh/gist:267470
# Installing Rails 3.0.pre in it's own gemset using rvm.
# I use Ruby Enterprise Edition for rails development.
# You might want to replace ree with Your Favorite Ruby Implementation(tm)
rvm use ree%rails3 # Create new gemset called rails3.
gem install rake rack test-spec thor sqlite3-ruby # Get some gems we'll need (rails3 gemset should be empty)
git clone git://github.com/rails/rails.git && cd rails # Get rails source.
git submodule init && git submodule update # Get git dependencies.
rake package && gem install -f */pkg/*.gem pkg/*.gem # Create gems and install
cd arel && thor :build && thor :install && cd ../.. # Install arel
#! /bin/sh
### BEGIN INIT INFO
# Provides: redis-server
# Required-Start: $syslog
# Required-Stop: $syslog
# Should-Start: $local_fs
# Should-Stop: $local_fs
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: redis-server - Persistent key-value db
# Installing Rails 3.0.pre in it's own gemset using rvm.
# I use Rube Enterprise Edition for rails development.
# You might want to replace ree with Your Favorite Ruby Implementation(tm)
rvm use ree%rails3 # Create new gemset called rails3.
gem install rake test-spec thor sqlite3-ruby rack bundler # Get some gems we'll need (rails3 gemset should be empty)
git clone git://github.com/rails/rails.git && cd rails # Get rails source.
rake gem # build rails 3.pre
git submodule init && git submodule update # Get git dependencies.
cd arel && thor :build && thor :install && cd ../.. # Install arel
@jsmestad
jsmestad / .gems
Created December 14, 2009 18:55 — forked from mulder/.gems
jekyll