install cycript
brew install https://gist.github.com/raw/890258/cycript.rb
wget https://gist.github.com/raw/890258/hack_propane.js
chmod +x hack_propane.js
#!/usr/bin/ruby | |
require 'rubygems' | |
require 'osx/cocoa' | |
require 'nokogiri' | |
require 'open-uri' | |
require 'nkf' | |
require 'pp' | |
OSX.require_framework 'Skype' | |
diff --git a/array.c b/array.c | |
index b1616c5..16326fc 100644 | |
--- a/array.c | |
+++ b/array.c | |
@@ -302,7 +302,7 @@ ary_alloc(VALUE klass) | |
return (VALUE)ary; | |
} | |
-static VALUE | |
+VALUE |
require 'rake/clean' | |
HAML = FileList['**/*.haml'] | |
LESS = FileList['**/*.less'] | |
COFFEE = FileList['**/*.coffee'] | |
HTML = HAML.ext('html') | |
CSS = LESS.ext('css') | |
JS = COFFEE.ext('js') |
>> load './RUNME-demo_of_async_fibers.rb' | |
/Users/flip/ics/backend/son_of_a_batch/RUNME-demo_of_async_fibers.rb:4: warning: already initialized constant FIBER_IDXS | |
814e5e90 0 f_0 beg main top level | |
814e5e90 1 f_0 beg em setup this block sets up the eventmachine execution, but no execution-order shenanigans yet | |
814e5e90 2 f_0 beg fiber stp the end-the-reactor block won't be called for 1.5s, so we get here immediately. | |
814e5e90 3 f_0 end fiber stp nothing from inside the Fiber.new{} block has run yet. | |
814e5e90 4 f_0 end fiber stp kick off the fiber... | |
80d829a0 5 f_1 beg fiber when my_fiber.resume is called, this runs. Now in a new fiber | |
80d829a0 6 f_1 beg get_result get_result is called from within fiber_1 | |
80d829a0 7 f_1 setup callback set up some code to run 1.5s from now |
# vmc update is great for test and development, however it stops your old app and stages and starts the new one, | |
# resulting in dropped requests. | |
# If you want to update an application without dropping user requests, see below. | |
# NOTE: This change assumes your application can share services, etc with the new version. | |
# Assume my app is named foo | |
vmc push foo-v2 --url foov2.cloudfoundry.com |
Jeremy | |
Absolutely brilliant | |
both technically | |
and oratorically | |
He wrote CoffeeScript | |
1st place 5k | |
21 min, 3 seconds | |
<7min mile | |
Big picture |
UPDATE: Please see some of the forks for an updated version of this guide. I | |
myself have moved onto the Rails 3.1 betas to get the asset pipeline. But if | |
you want to stay on stable there are other folks who are keeping this guide | |
relevant despite the changes constantly occurring on Sprockets 2. The comments | |
on this gist will lead you to the right forks. :) | |
Some brief instructions on how to use Sprocket 2 in Rails to get CoffeeScript | |
powered JS and SASS powered CSS with YUI compression all via the magic of rack. | |
This stuff will be native in Rails 3.1 and the layout of the files on the |
brew install https://gist.github.com/raw/890258/cycript.rb
wget https://gist.github.com/raw/890258/hack_propane.js
chmod +x hack_propane.js
require('soda').createSauceClient({ 'username': 'username-string', 'access-key': 'access-key-string', | |
'url': 'http://example.saucelabs.com/', 'max-duration': 300, | |
'os': 'Windows 2003', 'browser': 'firefox', 'browser-version': '3.6', | |
'name': 'This is an example test' }).chain.session() | |
.open('/') | |
.getTitle(function(title){ | |
require('assert').ok(~title.indexOf('Cross browser testing with Selenium - Sauce Labs'), 'Title did not include the query'); | |
}) | |
.testComplete() | |
.end(function(err){ |
function edit { | |
if [[ "$1" == "" ]]; then echo "usage: edit NAME (NAME is a bundled gem or npm package)"; return; fi | |
RES=$(git rev-parse --quiet --is-inside-work-tree 2>&1) | |
if [[ "$?" == "0" ]]; then | |
GIT_DIR=$(git rev-parse --show-toplevel) | |
if [[ -f "$GIT_DIR/package.json" ]]; then | |
npm edit $1 | |
fi | |
if [[ -f "$GIT_DIR/Gemfile" ]]; then | |
bundle open $1 |