Just install this in your apps like so:
gem 'test-spec-mini', :git => 'git://gist.github.com/1806986.git', :require => 'mini'
module Helpers | |
def sign_in(user) | |
@user_session = UserSession.create user | |
end | |
def fill_in_autocomplete(selector, value) | |
page.execute_script %Q{$('#{selector}').val('#{value}').keydown()} | |
end | |
def choose_autocomplete(text) |
module Helpers | |
def sign_in(user) | |
@user_session = UserSession.create user | |
end | |
def fill_in_autocomplete(selector, value) | |
page.execute_script %Q{$('#{selector}').val('#{value}').keydown()} | |
end | |
def choose_autocomplete(text) |
Just install this in your apps like so:
gem 'test-spec-mini', :git => 'git://gist.github.com/1806986.git', :require => 'mini'
This installs a patched ruby 1.9.3-p327 with various performance improvements and a backported COW-friendly GC, all courtesy of funny-falcon.
You will also need a C Compiler. If you're on Linux, you probably already have one or know how to install one. On OS X, you should install XCode, and brew install autoconf
using homebrew.
// main app.js | |
var client = require('ranger').createClient('ROOM', | |
'SECRET'); | |
var timestamp = require('./timestamp').timestamp; | |
var getWeatherWrapper = require('./weather').getWeatherWrapper; | |
var showMap = require('./map').showMap; | |
var getTweets = require('./tweets').getTweets; | |
client.room(ROOMID, function(room) { |
rails_root = ENV['RAILS_ROOT'] || File.dirname(__FILE__) + '/../..' | |
rails_env = ENV['RAILS_ENV'] || 'development' | |
resque_config = YAML.load_file(rails_root + '/config/resque.yml') | |
Resque.redis = resque_config[rails_env] | |
#secure the admin view of resque | |
Resque::Server.use(Rack::Auth::Basic) do |user, password| | |
password == "secret" | |
end |
# Module Dependencies | |
express = require 'express' | |
app = module.exports = express.createServer(); | |
# Configuration | |
app.configure () -> | |
app.set 'views', "#{__dirname}/views" | |
app.set 'view engine', 'jade' |
<html> | |
<head></head> | |
<body style="background-color:#ffffff;margin:10px"> | |
<script> | |
var uploadFile = function(){ | |
var text = document.getElementById('txt'); | |
var dir = Titanium.Filesystem.getResourcesDirectory(); | |
sep = Titanium.Filesystem.getSeparator(), | |
// filename = 'test.txt', |
" by CJ Lazell github.com/cj | |
" based on - http://github.com/solars/github-vim/ | |
if exists("loaded_github") || &cp | |
finish | |
endif | |
" --- main functions --- " |