application.scss.erb - use <%= asset_path 'background.jpg' %>
on config/environments/production.rb
# Poor Man's Fiber (API compatible Thread based Fiber implementation for Ruby 1.8) | |
# (c) 2008 Aman Gupta (tmm1) | |
unless defined? Fiber | |
require 'thread' | |
class FiberError < StandardError; end | |
class Fiber | |
def initialize |
module RegexpBuilder | |
module RegexpExt | |
class Builder | |
class RegexpSource | |
def initialize x | |
@src = if x.is_a? self.class | |
x.to_s | |
else | |
x | |
end |
08:58 Defi_: can anyone tell me if there are any obvious disadvantages to patching a blocking library to use fibers at the socket level? | |
08:58 Defi_: its far too much effort to have to rewrite large chunks of every library just to make it async and fiber-aware | |
08:59 raggi: if it uses non-stack stored state you could end up with concurrency issues (read: race conditions) | |
08:59 raggi: fibers as implemented in MRI have limited size stacks (4kb) | |
09:00 Defi_: hmm alright :/ | |
09:01 raggi: if the library is trying to be thread safe, it can make a real mess too | |
09:01 raggi: Defi_: just use threads. | |
09:02 Defi_: raggi: not gonna happen... | |
09:02 Defi_: even if this was a personal project, i wouldnt use threads | |
09:03 Defi_: guess ill just have to continue rewriting parts of a bunch of libs as i go |
#define STRING char * | |
#define IF if( | |
#define THEN ){ | |
#define ELSE } else { | |
#define FI ;} | |
#define WHILE while ( | |
#define DO ){ | |
#define OD ;} | |
#define INT int | |
#define BEGIN { |
# Tab Completion | |
require "irb/completion" | |
require "rubygems" | |
# from https://github.com/aniero/dotfiles/blob/master/irbrc | |
# Assume a bundler-managed environment, so find and require the irb-specific | |
# enhancement gems directly. This does not do dependency tracking, so | |
# dependent gems must be explicitly specified! | |
def irb_require(gemname, lib=nil) | |
# allow bundler or rubygems a fair shake at loading the library first |
---------- Forwarded message ----------
From: Mark S. Miller <[email protected]>
Date: Tue, Nov 16, 2010 at 3:44 PM
Subject: "Future of Javascript" doc from our internal "JavaScript Summit"
last week
To: [email protected]
2 tone | |
2-step garage | |
4-beat | |
4x4 garage | |
8-bit | |
acapella | |
acid | |
acid breaks | |
acid house | |
acid jazz |
>> IF = -> b { b } | |
=> #<Proc:0x007fb4e4049cc8 (lambda)> | |
>> LEFT = -> p { p[-> x { -> y { x } } ] } | |
=> #<Proc:0x007fb4e403d680 (lambda)> | |
>> RIGHT = -> p { p[-> x { -> y { y } } ] } | |
=> #<Proc:0x007fb4e4028ff0 (lambda)> | |
>> IS_EMPTY = LEFT |