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.
var http = require("http"), | |
url = require("url"), | |
path = require("path"), | |
fs = require("fs") | |
port = process.argv[2] || 8888; | |
http.createServer(function(request, response) { | |
var uri = url.parse(request.url).pathname | |
, filename = path.join(process.cwd(), uri); |
namespace :db do | |
def local_database?(config, &block) | |
if config['host'].in?(['127.0.0.1', 'localhost', '192.168.30.1']) || config['host'].blank? | |
yield | |
else | |
$stderr.puts "This task only modifies local databases. #{config['database']} is on a remote host." | |
end | |
end | |
end |
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.