This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ========================================================================== | |
// Listenapp.App Fixtures | |
// ========================================================================== | |
sc_require('models/nav'); | |
Listenapp.Nav.STATIC = SC.Object.create({ | |
// TODO: Add your data fixtures here. | |
// All fixture records must have a unique guid and a type matching the |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ========================================================================== | |
// Project: SproutCore - JavaScript Application Framework | |
// Copyright: ©2006-2009 Sprout Systems, Inc. and contributors. | |
// Portions ©2008-2009 Apple, Inc. All rights reserved. | |
// License: Licened under MIT license (see license.js) | |
// ========================================================================== | |
/** @class | |
TODO: Describe Class |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ========================================================================== | |
// Project: SproutCore - JavaScript Application Framework | |
// Copyright: ©2006-2009 Sprout Systems, Inc. and contributors. | |
// Portions ©2008-2009 Apple, Inc. All rights reserved. | |
// License: Licened under MIT license (see license.js) | |
// ========================================================================== | |
/** @class | |
TODO: Describe Class |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SC.RecordAttribute.registerTransform(SC.DateTime, { | |
/** Transforms a date to an integer of milliseconds since 1970 */ | |
/** @private - convert an int to a date */ | |
to: function(n, attr) { | |
/* Transform a date coming from rails in the format 2008/12/31 10:45:23 +0200 */ | |
return SC.DateTime.parse(n,'%Y/%m/%d %H:%M:%S'); | |
}, | |
/** @private - convert a date to an int */ | |
from: function(date) { | |
return date.get('milliseconds'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'rubygems' | |
require 'daemons' | |
options = { | |
:app_name => "task_server", | |
:dir_mode => :script, | |
:dir => "../log", # where the log/PID file will be dropped | |
:ontop => false, # should be false | |
:mode => :exec, | |
:backtrace => true, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ActiveRecord::Schema.define(:version => 20091018223040) do | |
create_table "assets", :force => true do |t| | |
t.string "content_type" | |
t.string "filename" | |
t.integer "size" | |
t.integer "parent_id" | |
t.integer "site_id" | |
t.datetime "created_at" | |
t.string "title" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set :mongrel_base_port, 5000 | |
set :mongrel_restart_delay, 30 | |
set :mongrel_count, 2 | |
namespace :mongrel do | |
task :restart, :roles => [:app], :except => {:mongrel => false} do | |
(mongrel_base_port..(mongrel_base_port+mongrel_count)).to_a.each do |port| | |
sudo "/usr/bin/monit restart mongrel_#{monit_group}_#{port}" | |
sleep mongrel_restart_delay | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This example shows how to setup an environment running Rails 3 beta under 1.9.1 with a 'rails3' gem set. | |
∴ rvm update --head | |
# ((Open a new shell)) | |
# If you do not already have the ruby interpreter installed, install it: | |
∴ rvm install 1.9.1 | |
# Switch to 1.9.1 | |
∴ rvm 1.9.1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
check process rabbitmq_appname | |
with pidfile /var/run/rabbitmq/rabbitmq.pid | |
start program = "/engineyard/bin/rabbitmq" | |
stop program = "/engineyard/bin/rabbitmq" | |
group rabbitmq_appname |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Simple deployment script | |
# | |
# Requires access to to github repository, as well as a host defined in | |
# ~/.ssh/config like so: | |
# | |
# Host myhost | |
# User appuser | |
# Hostname hostname |