NOTE: This post now lives (and kept up to date) on my blog: http://hakunin.com/rails3-load-paths
Do nothing. All files in this dir are eager loaded in production and lazy loaded in development by default.
NOTE: This post now lives (and kept up to date) on my blog: http://hakunin.com/rails3-load-paths
Do nothing. All files in this dir are eager loaded in production and lazy loaded in development by default.
TERMINATORS = ["\n", ";"] | |
ESC = "\\" | |
QUOTES = ['"', "'"] | |
class c: | |
""" | |
Will be at the start of a list representing an expression | |
in curly braces. Every c() is equal to any other c() | |
""" |
var exportToDir = "/Users/julik/Code/apps/mvp/public/icons/"; | |
/* Crop every icon in your Illustrator file witha named artboard. This script will export them all */ | |
var docRef = app.activeDocument; | |
docRef.save(); | |
// Get the source path | |
var originalPath = app.activeDocument.fullName.toString(); | |
// Allocate a copy of the current document that we will throw away. We do this |
uniform sampler2D input1; | |
uniform float adsk_input1_w, adsk_result_w; | |
void main() | |
{ | |
// this should output the width of the input1 into the G channel of the shader, | |
// but it's value is always zero. And it wasn't. The test_shader stipulates that | |
// adsk_{sampler_name}_w / adsk_{sampler_name}_h : when declared as a float | |
// uniform, this gives access to each texture's resolution | |
// but it's broken now |
// Detect Control/Shift/Alt key status | |
var CTRL = false; | |
var SHIFT = false; | |
var ALT = false; | |
var CHAR_CODE = -1; | |
var menuItemDiv = null; | |
var curMouseX, curMouseY; |
readgeo = nuke.selectedNode() | |
# register the first frame of the selected readgeo | |
hold_first = int(readgeo["range_first"].value()) | |
# and the last frame | |
hold_last = int(readgeo["range_last"].value()) | |
# generate the holds | |
hold_before = nuke.nodes.FrameHold(first_frame = hold_first) | |
hold_before.setInput(0, readgeo) |
#! /usr/bin/env ruby | |
# "Fork and Forget" | |
# Don't wait if you don't have to: A mini-tutorial about concurrency | |
# mechanisms in Ruby and basic Unix systems programming, and how you can use | |
# them to avoid waiting. | |
# | |
# I have heard that people are occasionally unfamiliar with this strategy. | |
# It's a common idiom, regardless of language, and it is also essentially built | |
# into Erlang (and Termite Scheme, etc.). | |
# |
def path | |
super || own_computed_path | |
end | |
private | |
def own_computed_path | |
path_components = [parent_path] | |
if node_id && !parent_path.empty? | |
path_components.push '[%s]' % node_id |
class OxMama | |
def path | |
end | |
end | |
class WyrwiGlaz < OxMama | |
def parent_path | |
'junk' | |
end | |
using = (context, args..., f) -> f.apply(context, args) | |
window.app = {} | |
window.inApp = (f) -> | |
using window.app, f | |