This file contains 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 'mongoid' | |
Mongoid.configure do |config| | |
config.master = Mongo::Connection.new.db("mongoid_key_test") | |
end | |
Mongoid.master.collection("users").drop | |
class User |
This file contains 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
# Cookbooks and DNA stored within app codebase | |
# Pro: no separate repo for deploy config/setup | |
# Con: keeping sync'd with changes to eycloud-recipes repo harder (solve w/ subtree?) | |
# Structure | |
railsapp | |
|-- deploy | |
| |-- after_restart.rb | |
| |-- before_migrate.rb |
This file contains 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
~ $ rvm --trace update | |
+__rvm_parse_args:414> [[ -z 4.3.9 ]] | |
+__rvm_parse_args:570> [[ -z '' && -n '' ]] | |
+__rvm_parse_args:572> [[ 0 -eq 1 || -n '' ]] | |
+__rvm_parse_args:15> [[ -n update ]] | |
+__rvm_parse_args:17> rvm_token=update | |
+__rvm_parse_args:19> [[ 0 -gt 0 ]] | |
+__rvm_parse_args:19> next_token='' | |
+__rvm_parse_args:21> case update (fetch|version|srcdir|reset|debug|reload|update|monitor|notes|implode|seppuku|question|answer|env) | |
+__rvm_parse_args:23> rvm_action=update |
This file contains 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
$(document).ready -> | |
$('#progress').ajaxStart -> | |
$(@).show() | |
$('#progress').ajaxStop -> | |
$(@).hide() |
This file contains 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
~ $ rvm use jruby-head | |
Using /Users/hpoydar/.rvm/gems/jruby-head | |
~ $ jruby -v | |
jruby 1.7.0.dev (ruby-2.0.0dev) (2012-03-16 61bd77a) (OpenJDK 64-Bit Server VM 1.7.0-u4-b13) [darwin-amd64-java] | |
~ $ jruby --1.9 -v | |
jruby 1.7.0.dev (ruby-2.0.0dev) (2012-03-16 61bd77a) (OpenJDK 64-Bit Server VM 1.7.0-u4-b13) [darwin-amd64-java] | |
~ $ |
This file contains 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
... | |
gem "newrelic_rpm", "~> 3.5.3.25", :require => false | |
... |
This file contains 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
#RP5_HOME: "" # windoes users should set this | |
PROCESSING_ROOT: "/usr/share/processing" # Works for ArchLinux | |
#PROCESSING_ROOT: "/home/tux/processing-2.1.0" # Other linux distros with user tux | |
#PROCESSING_ROOT: "/Applications/Processing.app/Contents/Resources/Java" # Path for Mac? | |
#PROCESSING_ROOT: "C:\Java\processing-2.1.0" # if you follow PhiLhos suggestion for windoes |
This file contains 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
namespace :deploy do | |
desc "Tag a release and deploy the application to production" | |
task :production do | |
release_tag_name = "release-#{Time.now.utc.strftime('%Y%m%d.%H%M')}" | |
sh "git push origin integration" | |
sh "git checkout master" | |
sh "git merge integration" |
This file contains 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
/*===== | |
HIDING | |
====== | |
/* Hide the Google+ buttons */ | |
/* | |
.gb_ea, | |
.gb_fa | |
{ display: none; } | |
*/ |
This file contains 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
RSpec.configure do |config| | |
config.before(:suite) do | |
DatabaseCleaner.clean_with(:truncation) | |
load "#{Rails.root}/db/seeds.rb" | |
end | |
config.before(:each) do | |
DatabaseCleaner.strategy = :transaction |